Skip to content

Commit

Permalink
Reintroduce initial support for Cypress Cloud
Browse files Browse the repository at this point in the history
This should allow running tests in parallel to provide a faster testing
process. Also it may provide a better test debugging experience.

All setup is based on the example from the documentation:
https://github.com/cypress-io/github-action#split-install-and-tests

This reverts commit 773bb0a.
  • Loading branch information
kasperg committed Dec 28, 2023
1 parent e0f203e commit 619179a
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 1 deletion.
15 changes: 15 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,14 @@ jobs:
options: --user 1001
env:
TZ: Europe/Copenhagen
strategy:
# When one test fails, DO NOT cancel the other containers, because this
# will kill Cypress processes leaving Cypress Cloud hanging.
# https://github.com/cypress-io/github-action/issues/48
fail-fast: false
matrix:
# Run 3 copies of the current job in parallel
containers: [1, 2, 3]
steps:
- uses: actions/checkout@master
- name: Setup Node
Expand All @@ -28,9 +36,16 @@ jobs:
- name: Cypress run
uses: cypress-io/github-action@v6
with:
install: false
start: yarn start:storybook:test
wait-on: "http://localhost:57021"
browser: chrome
group: "Integration tests"
parallel: true
record: true
env:
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Upload screenshots
uses: actions/upload-artifact@v4
if: failure()
Expand Down
3 changes: 2 additions & 1 deletion cypress.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,6 @@
"retries": {
"runMode": 3,
"openMode": 0
}
},
"projectId": "4trcdv"
}

0 comments on commit 619179a

Please sign in to comment.