Change owning side of relationship, add test. #34
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: Test E2E | |
on: push | |
env: | |
APP_ENV: test | |
NODE_ENV: test | |
jobs: | |
E2E: | |
name: Run end to end tests with cypress | |
runs-on: ubuntu-latest | |
env: | |
GEOCODE_EARTH_API_KEY: ${{ secrets.GEOCODE_EARTH_API_KEY }} | |
STRIPE_PUBLISHABLE_KEY: ${{ secrets.STRIPE_PUBLISHABLE_KEY }} | |
STRIPE_SECRET_KEY: ${{ secrets.STRIPE_SECRET_KEY }} | |
STRIPE_CONNECT_CLIENT_ID: ${{ secrets.STRIPE_CONNECT_CLIENT_ID }} | |
AWS_ENDPOINT: ${{ secrets.AWS_ENDPOINT }} | |
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
steps: | |
- name: Set timezone | |
uses: szenius/set-timezone@v2.0 | |
with: | |
timezoneLinux: "Europe/Paris" | |
- uses: actions/checkout@v2 | |
- name: Run CoopCycle Web | |
uses: ./.github/actions/run-coopcycle-web | |
timeout-minutes: 5 | |
- name: Setup CoopCycle | |
run: docker compose exec -T php bin/console coopcycle:setup --env=test | |
- name: Run Cypress | |
uses: cypress-io/github-action@v6 | |
with: | |
# Maybe we could run a build step before starting tests | |
# https://symfony.com/doc/current/frontend/encore/installation.html | |
# https://github.com/cypress-io/github-action?tab=readme-ov-file#build-app | |
# build: npm run dev | |
spec: | | |
cypress/e2e/**/*.cy.js | |
# after the test run completes store videos and any screenshots | |
- name: Upload images for failed tests | |
uses: actions/upload-artifact@v4 | |
if: failure() | |
with: | |
name: cypress-screenshots | |
path: cypress/screenshots | |
if-no-files-found: ignore # 'warn' or 'error' are also available, defaults to `warn` | |
- name: Show Symfony warnings on failure | |
if: failure() | |
uses: ./.github/actions/show-symfony-warnings | |
- name: Upload Symfony logs on failure | |
if: failure() | |
uses: ./.github/actions/upload-symfony-logs |