From 7f73b99470fa8c2885eea9369a62bfc21a2a0aa3 Mon Sep 17 00:00:00 2001 From: Wing-Kam Wong Date: Tue, 6 Sep 2022 12:47:27 +0800 Subject: [PATCH] chore: change cypress-v2 to cypress --- scripts/cypress/cypress.json | 14 +++++++------- .../cypress/integration/common/6g_base_share.js | 4 ++-- .../common/7a_create_project_from_excel.js | 4 ++-- scripts/cypress/plugins/index.js | 6 +++--- 4 files changed, 14 insertions(+), 14 deletions(-) diff --git a/scripts/cypress/cypress.json b/scripts/cypress/cypress.json index 4a5342dd76..2d162a3676 100644 --- a/scripts/cypress/cypress.json +++ b/scripts/cypress/cypress.json @@ -41,12 +41,12 @@ "sharedBase": "https://airtable.com/shr4z0qmh6dg5s3eB" } }, - "fixturesFolder": "scripts/cypress-v2/fixtures", - "integrationFolder": "scripts/cypress-v2/integration", - "pluginsFile": "scripts/cypress-v2/plugins/index.js", - "screenshotsFolder": "scripts/cypress-v2/screenshots", - "videosFolder": "scripts/cypress-v2/videos", - "downloadsFolder": "scripts/cypress-v2/downloads", - "supportFile": "scripts/cypress-v2/support/index.js", + "fixturesFolder": "scripts/cypress/fixtures", + "integrationFolder": "scripts/cypress/integration", + "pluginsFile": "scripts/cypress/plugins/index.js", + "screenshotsFolder": "scripts/cypress/screenshots", + "videosFolder": "scripts/cypress/videos", + "downloadsFolder": "scripts/cypress/downloads", + "supportFile": "scripts/cypress/support/index.js", "chromeWebSecurity": false } diff --git a/scripts/cypress/integration/common/6g_base_share.js b/scripts/cypress/integration/common/6g_base_share.js index a741841988..94ba459d0e 100644 --- a/scripts/cypress/integration/common/6g_base_share.js +++ b/scripts/cypress/integration/common/6g_base_share.js @@ -113,7 +113,7 @@ style="background: transparent; "> `; cy.writeFile( - "scripts/cypress-v2/fixtures/sampleFiles/iFrame.html", + "scripts/cypress/fixtures/sampleFiles/iFrame.html", htmlFile ); }); @@ -156,7 +156,7 @@ style="background: transparent; "> // https://docs.cypress.io/api/commands/visit#Prefixes it("Generate & verify embed HTML IFrame", {baseUrl: null}, () => { - let filePath = "scripts/cypress-v2/fixtures/sampleFiles/iFrame.html"; + let filePath = "scripts/cypress/fixtures/sampleFiles/iFrame.html"; cy.log(filePath); cy.visit(filePath, {baseUrl: null}); diff --git a/scripts/cypress/integration/common/7a_create_project_from_excel.js b/scripts/cypress/integration/common/7a_create_project_from_excel.js index 8bc8d93b4f..209c1dd2b3 100644 --- a/scripts/cypress/integration/common/7a_create_project_from_excel.js +++ b/scripts/cypress/integration/common/7a_create_project_from_excel.js @@ -75,14 +75,14 @@ export const genTest = (apiType, dbType) => { cy.wait(1000); cy.task("readSheetList", { - file: `./scripts/cypress-v2/fixtures/${filepath}`, + file: `./scripts/cypress/fixtures/${filepath}`, }).then((rows) => { cy.log(rows); sheetList = rows; }); cy.task("readXlsx", { - file: `./scripts/cypress-v2/fixtures/${filepath}`, + file: `./scripts/cypress/fixtures/${filepath}`, sheet: "Sheet2", }).then((rows) => { cy.log(rows); diff --git a/scripts/cypress/plugins/index.js b/scripts/cypress/plugins/index.js index 07ab95acc6..84d7ffd618 100644 --- a/scripts/cypress/plugins/index.js +++ b/scripts/cypress/plugins/index.js @@ -29,7 +29,7 @@ module.exports = (on, config) => { copyFile() { console.log("copyFile", __dirname) return new Promise((resolve, reject) => { - copyFile("./scripts/cypress-v2/fixtures/quickTest/noco_0_91_7.db", "./packages/nocodb/noco.db", (err) => { + copyFile("./scripts/cypress/fixtures/quickTest/noco_0_91_7.db", "./packages/nocodb/noco.db", (err) => { if(err) { console.log(err) return reject(err) @@ -129,7 +129,7 @@ function _sqliteExecReturnValue(query) { // open the database console.log("Current directory: " + process.cwd()); let db = new sqlite3.Database( - "./scripts/cypress-v2/fixtures/sqlite-sakila/sakila.db", + "./scripts/cypress/fixtures/sqlite-sakila/sakila.db", sqlite3.OPEN_READWRITE, (err) => { if (err) { @@ -157,7 +157,7 @@ function _sqliteExec(query) { // open the database console.log("Current directory: " + process.cwd()); let db = new sqlite3.Database( - "./scripts/cypress-v2/fixtures/sqlite-sakila/sakila.db", + "./scripts/cypress/fixtures/sqlite-sakila/sakila.db", sqlite3.OPEN_READWRITE, (err) => { if (err) {