Cypress Tests #30
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Cypress Tests | |
on: | |
push: | |
branches: | |
- main | |
workflow_dispatch: | |
jobs: | |
cypress-run: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v2 | |
- name: Install Dependencies | |
run: npm install | |
- name: Run Cypress Tests | |
id: cypress | |
uses: cypress-io/github-action@v6 | |
with: | |
browser: chrome | |
headless: true | |
spec: cypress/integration/sample.spec.js | |
record: false | |
parallel: false | |
retries: 2 | |
- name: Run Cypress Tests Additional Times | |
run: | | |
for run in {1..4}; do | |
bash -c "$CYPRESS_CACHE_FOLDER/Cypress/Cypress\ ${{ steps.cypress.outputs.version }}/cypress run --browser chrome --headless --spec 'cypress/integration/sample.spec.js'" | |
done |