diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index 371764a6a..2d5abdf41 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -60,8 +60,8 @@ jobs: - name: Run Cypress tests run: - npm run cy:run -- --spec "**/kit/${{ matrix.project }}/**/*.cy.ts" --config baseUrl="${{ env.UNIVERSAL_SERVER - }}" + npx nx e2e demo-integrations --spec="**/kit/${{ matrix.project }}/**/*.cy.ts" --baseUrl=${{ + env.UNIVERSAL_SERVER}} e2e-recipes: if: ${{ !contains(github.head_ref, 'release/') }} @@ -85,7 +85,7 @@ jobs: curl -X GET -I -f "${{ env.UNIVERSAL_SERVER }}" - name: Run Cypress tests - run: npm run cy:run -- --spec "**/recipes/**/*.cy.ts" --config baseUrl="${{ env.UNIVERSAL_SERVER }}" + run: npx nx e2e demo-integrations --spec="**/recipes/**/*.cy.ts" --baseUrl=${{ env.UNIVERSAL_SERVER}} e2e-others: if: ${{ !contains(github.head_ref, 'release/') }} @@ -112,8 +112,8 @@ jobs: # Replace with npm run cy:run -- --spec "**/!(kit|recipes)/*.cy.ts" --config baseUrl="${{ env.UNIVERSAL_SERVER }}" # After this issue fix: https://github.com/cypress-io/cypress/issues/22407 run: - npm run cy:run -- --spec "**/(angular|react|ssr|addons|others)/**/*.cy.ts" --config baseUrl="${{ - env.UNIVERSAL_SERVER }}" + npx nx e2e demo-integrations --spec="**/(angular|react|ssr|addons|others)/**/*.cy.ts" --baseUrl=${{ + env.UNIVERSAL_SERVER}} component-testing: if: ${{ !contains(github.head_ref, 'release/') }} diff --git a/package.json b/package.json index 90e9d243a..176bb1f07 100644 --- a/package.json +++ b/package.json @@ -53,7 +53,7 @@ "build:prerender": "nx run demo:prerender", "*** Cypress ***": "", "cy:open": "cypress open --project ./projects/demo-integrations/", - "cy:run": "cypress run --project ./projects/demo-integrations/ --browser chrome", + "cy:run": "nx e2e demo-integrations", "*** Release ***": "", "release": "standard-version -a --no-verify", "release:patch": "npm run release -- --release-as patch", diff --git a/projects/demo-integrations/project.json b/projects/demo-integrations/project.json index 94a636668..54ca957fa 100644 --- a/projects/demo-integrations/project.json +++ b/projects/demo-integrations/project.json @@ -9,6 +9,8 @@ "options": { "cypressConfig": "{projectRoot}/cypress.config.ts", "testingType": "e2e", + "skipServe": true, + "browser": "chrome", "devServerTarget": "demo:serve:development" } },