test: playwright test corrections

This commit is contained in:
Pranav C
2024-02-07 12:26:50 +00:00
parent c3f1a58d68
commit f90cf260e5
5 changed files with 21 additions and 13 deletions

View File

@@ -410,9 +410,9 @@ const setup = async ({
// ignore error: some roles will not have permission for license reset
// console.error(`Error resetting base: ${process.env.TEST_PARALLEL_INDEX}`, e);
}
await page.addInitScript(
async ({ token }) => {
if (location.search?.match(/code=|short-token=/)) return;
try {
let initialLocalStorage = {};
try {
@@ -420,6 +420,9 @@ const setup = async ({
} catch (e) {
console.error('Failed to parse local storage', e);
}
if (initialLocalStorage?.token) return;
window.localStorage.setItem(
'nocodb-gui-v2',
JSON.stringify({