ci: despair #41
Workflow file for this run
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 E2E | |
on: | |
push: | |
schedule: | |
- cron: '1 0-12,20-23 * * 1-5' | |
- cron: '1 * * * 0,6' | |
jobs: | |
url-maker: | |
runs-on: ubuntu-latest | |
outputs: | |
URL: ${{ steps.step1.outputs.test }} | |
steps: | |
- id: step1 | |
run: echo "test=https://ipcvji5lohipaep3lgjypxrlem0tmxax.lambda-url.ca-central-1.on.aws/" >> $GITHUB_OUTPUT | |
cypress-e2e: | |
runs-on: ubuntu-latest | |
needs: url-maker | |
# services: | |
# postgres: | |
# image: postgres:11.17-bullseye | |
# env: | |
# POSTGRES_USER: postgres | |
# POSTGRES_PASSWORD: postgres | |
# POSTGRES_DB: test_notification_api | |
# ports: | |
# - 5432:5432 | |
# options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 | |
# cypress: | |
# image: cypress/included:12.16.0 | |
steps: | |
- env: | |
CYPRESS_BASE_URL: ${{needs.url-maker.outputs.URL}} | |
run: echo HEY "$CYPRESS_BASE_URL" | |
- name: checkout repo | |
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 | |
- name: setup node | |
uses: actions/setup-node@e33196f7422957bea03ed53f6fbb155025ffc7b8 # v3.7.0 | |
- name: Write the cypress.env.json file | |
# use quotes around the secret, as its value | |
# is simply inserted as a string into the command | |
run: | | |
echo '${{ secrets.CYPRESS_ENV_JSON }}' > tests_cypress/cypress.env.json | |
- uses: cypress-io/github-action@d79d2d530a66e641eb4a5f227e13bc985c60b964 # v4.2.2 | |
env: | |
CYPRESS_BASE_URL: ${{needs.url-maker.outputs.URL}} | |
with: | |
working-directory: tests_cypress | |
build: npx cypress info | |
spec: cypress/e2e/admin/a11y/app_pages.cy.js | |