From d55c69f04eb161ea67c7ba61289738c575ada78f Mon Sep 17 00:00:00 2001 From: Abdulrhmn Ghanem Date: Fri, 21 Jul 2023 19:09:54 +0300 Subject: [PATCH] e2e: update the file structure to match v12 defaults --- e2e/cypress.config.js | 28 +++++++++++++++++++ e2e/cypress.json | 19 ------------- e2e/cypress/{integration => e2e}/IBOM.spec.js | 0 .../{integration => e2e}/IBOM.visual.spec.js | 0 .../{integration => e2e}/errorPage.spec.js | 0 .../legacyRedirect.spec.js | 0 .../{integration => e2e}/multiProject.spec.js | 0 .../{integration => e2e}/readme.spec.js | 0 .../{integration => e2e}/search.spec.js | 0 .../{integration => e2e}/syncRepo.spec.js | 0 e2e/cypress/support/{index.js => e2e.js} | 0 11 files changed, 28 insertions(+), 19 deletions(-) create mode 100644 e2e/cypress.config.js delete mode 100644 e2e/cypress.json rename e2e/cypress/{integration => e2e}/IBOM.spec.js (100%) rename e2e/cypress/{integration => e2e}/IBOM.visual.spec.js (100%) rename e2e/cypress/{integration => e2e}/errorPage.spec.js (100%) rename e2e/cypress/{integration => e2e}/legacyRedirect.spec.js (100%) rename e2e/cypress/{integration => e2e}/multiProject.spec.js (100%) rename e2e/cypress/{integration => e2e}/readme.spec.js (100%) rename e2e/cypress/{integration => e2e}/search.spec.js (100%) rename e2e/cypress/{integration => e2e}/syncRepo.spec.js (100%) rename e2e/cypress/support/{index.js => e2e.js} (100%) diff --git a/e2e/cypress.config.js b/e2e/cypress.config.js new file mode 100644 index 0000000000..b912eb5548 --- /dev/null +++ b/e2e/cypress.config.js @@ -0,0 +1,28 @@ +const { defineConfig } = require('cypress') + +module.exports = defineConfig({ + projectId: 'd8hk55', + experimentalFetchPolyfill: true, + numTestsKeptInMemory: 25, + includeShadowDom: true, + defaultCommandTimeout: 10000, + pageLoadTimeout: 80000, + viewportWidth: 1500, + viewportHeight: 800, + videoUploadOnPasses: false, + retries: { + runMode: 3, + }, + env: { + home_path: '/', + }, + e2e: { + // We've imported your old cypress plugins here. + // You may want to clean this up later by importing these. + setupNodeEvents(on, config) { + return require('./cypress/plugins/index.js')(on, config) + }, + baseUrl: 'http://kitspace.test:3000', + specPattern: 'cypress/e2e/**/*.{js,jsx,ts,tsx}', + }, +}) diff --git a/e2e/cypress.json b/e2e/cypress.json deleted file mode 100644 index f7bdd30280..0000000000 --- a/e2e/cypress.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "$schema": "https://raw.githubusercontent.com/cypress-io/cypress/develop/cli/schema/cypress.schema.json", - "projectId": "d8hk55", - "baseUrl": "http://kitspace.test:3000", - "experimentalFetchPolyfill": true, - "numTestsKeptInMemory": 25, - "includeShadowDom": true, - "defaultCommandTimeout": 10000, - "pageLoadTimeout": 80000, - "viewportWidth": 1500, - "viewportHeight": 800, - "videoUploadOnPasses": false, - "retries": { - "runMode": 3 - }, - "env": { - "home_path": "/" - } -} diff --git a/e2e/cypress/integration/IBOM.spec.js b/e2e/cypress/e2e/IBOM.spec.js similarity index 100% rename from e2e/cypress/integration/IBOM.spec.js rename to e2e/cypress/e2e/IBOM.spec.js diff --git a/e2e/cypress/integration/IBOM.visual.spec.js b/e2e/cypress/e2e/IBOM.visual.spec.js similarity index 100% rename from e2e/cypress/integration/IBOM.visual.spec.js rename to e2e/cypress/e2e/IBOM.visual.spec.js diff --git a/e2e/cypress/integration/errorPage.spec.js b/e2e/cypress/e2e/errorPage.spec.js similarity index 100% rename from e2e/cypress/integration/errorPage.spec.js rename to e2e/cypress/e2e/errorPage.spec.js diff --git a/e2e/cypress/integration/legacyRedirect.spec.js b/e2e/cypress/e2e/legacyRedirect.spec.js similarity index 100% rename from e2e/cypress/integration/legacyRedirect.spec.js rename to e2e/cypress/e2e/legacyRedirect.spec.js diff --git a/e2e/cypress/integration/multiProject.spec.js b/e2e/cypress/e2e/multiProject.spec.js similarity index 100% rename from e2e/cypress/integration/multiProject.spec.js rename to e2e/cypress/e2e/multiProject.spec.js diff --git a/e2e/cypress/integration/readme.spec.js b/e2e/cypress/e2e/readme.spec.js similarity index 100% rename from e2e/cypress/integration/readme.spec.js rename to e2e/cypress/e2e/readme.spec.js diff --git a/e2e/cypress/integration/search.spec.js b/e2e/cypress/e2e/search.spec.js similarity index 100% rename from e2e/cypress/integration/search.spec.js rename to e2e/cypress/e2e/search.spec.js diff --git a/e2e/cypress/integration/syncRepo.spec.js b/e2e/cypress/e2e/syncRepo.spec.js similarity index 100% rename from e2e/cypress/integration/syncRepo.spec.js rename to e2e/cypress/e2e/syncRepo.spec.js diff --git a/e2e/cypress/support/index.js b/e2e/cypress/support/e2e.js similarity index 100% rename from e2e/cypress/support/index.js rename to e2e/cypress/support/e2e.js