diff --git a/alfa-client/Jenkinsfile.e2e b/alfa-client/Jenkinsfile.e2e index da6cb44df78be1728b25743302200a8fd8d82106..c13f8975dc275c556dd65069bc154e2bf73a3b88 100644 --- a/alfa-client/Jenkinsfile.e2e +++ b/alfa-client/Jenkinsfile.e2e @@ -684,7 +684,7 @@ String generateCypressConfig(String bezeichner, String appName, String appVarian def namespace = generateNamespace(bezeichner) def configName = "cypress-ci-"+appVariant+".json" - dir('alfa-client/apps/${appName}/'){ + dir("alfa-client/apps/${appName}/"){ def config = readJSON file: 'cypress-ci.json' def vorgangManagerDatabaseSecret = getVorgangManagerDatabaseSecret(namespace); diff --git a/alfa-client/apps/admin-e2e/cypress-ci-main-tests.config.ts b/alfa-client/apps/admin-e2e/cypress-ci-main-tests.config.ts new file mode 100644 index 0000000000000000000000000000000000000000..debc5e3e19864e0afbd6b3376b24aec1be23d3c4 --- /dev/null +++ b/alfa-client/apps/admin-e2e/cypress-ci-main-tests.config.ts @@ -0,0 +1,25 @@ +import { nxE2EPreset } from '@nx/cypress/plugins/cypress-preset'; +import { defineConfig } from 'cypress'; + +//Cypress config is generated by JenkinsFile +const cypressConfig = require('./cypress-ci-main-tests.json'); +const cypressEvents = require('./src/support/cypress-tasks.ts'); + +export default defineConfig({ + e2e: { + ...nxE2EPreset(__dirname), + ...cypressConfig, + setupNodeEvents(on, config) { + return cypressEvents(on, config); + }, + }, + retries: { + experimentalStrategy: 'detect-flake-and-pass-on-threshold', + experimentalOptions: { + maxRetries: 2, + passesRequired: 1, + }, + openMode: true, + runMode: true, + }, +}); diff --git a/alfa-client/apps/admin-e2e/cypress-ci.json b/alfa-client/apps/admin-e2e/cypress-ci.json new file mode 100644 index 0000000000000000000000000000000000000000..b7768dbc3af38c4282d24c58f396f65d2ca20f3b --- /dev/null +++ b/alfa-client/apps/admin-e2e/cypress-ci.json @@ -0,0 +1,22 @@ +{ + "env": { + "database": "vorgang-manager-database", + "keycloakClient": "alfa" + }, + "fileServerFolder": ".", + "fixturesFolder": "./src/fixtures", + "modifyObstructiveCode": false, + "video": true, + "chromeWebSecurity": false, + "reporter": "../../node_modules/cypress-mochawesome-reporter", + "defaultCommandTimeout": 10000, + "supportFile": "./src/support/e2e.ts", + "testIsolation": false, + "reporterOptions": { + "html": false, + "json": true, + "quite": true, + "reportFilename": "report", + "overwrite": false + } +}