GHA Visual Acceptance: Build and start backend image for tests #9
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: Visual acceptance tests | |
on: | |
push: | |
pull_request: | |
# # Unkomment if you want a scheduled run | |
# | |
# on: | |
# workflow_dispatch: | |
# schedule: | |
# - cron: '0 */12 * * *' | |
env: | |
node-version: 22.x | |
jobs: | |
config: | |
runs-on: ubuntu-latest | |
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name | |
outputs: | |
base-tag: ${{ steps.vars.outputs.BASE_TAG }} | |
node-version: ${{ env.node-version }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Compute several vars needed for the CI | |
id: vars | |
run: | | |
echo 'BASE_TAG=sha-$(git rev-parse --short HEAD)' >> $GITHUB_OUTPUT | |
- name: Test vars | |
run: | | |
echo 'BASE_TAG=${{ steps.vars.outputs.BASE_TAG }}' | |
visualhomepage: | |
uses: ./.github/workflows/visual-acceptance.yml | |
name: Homepage | |
needs: | |
- config | |
with: | |
short-name: homepage | |
node-version: ${{ needs.config.outputs.node-version }} | |
spec: "cypress/tests/visual/homepage.cy.js" | |
visualcontent: | |
uses: ./.github/workflows/visual-acceptance.yml | |
name: Content | |
needs: | |
- config | |
with: | |
short-name: content | |
node-version: ${{ needs.config.outputs.node-version }} | |
spec: "cypress/tests/visual/content.cy.js" | |
visualblocksA: | |
uses: ./.github/workflows/visual-acceptance.yml | |
name: Blocks A | |
needs: | |
- config | |
with: | |
short-name: blocks-a | |
node-version: ${{ needs.config.outputs.node-version }} | |
spec: "cypress/tests/visual/blocks-A.cy.js" | |
visualblocksB: | |
uses: ./.github/workflows/visual-acceptance.yml | |
name: Blocks B | |
needs: | |
- config | |
with: | |
short-name: blocks-b | |
node-version: ${{ needs.config.outputs.node-version }} | |
spec: "cypress/tests/visual/blocks-B.cy.js" | |
visualblocksgrid: | |
uses: ./.github/workflows/visual-acceptance.yml | |
name: Blocks Grid | |
needs: | |
- config | |
with: | |
short-name: blocks-grid | |
node-version: ${{ needs.config.outputs.node-version }} | |
spec: "cypress/tests/visual/blocks-grid.cy.js" | |
visualblockslistingandsearch: | |
uses: ./.github/workflows/visual-acceptance.yml | |
name: Blocks Listing | |
needs: | |
- config | |
with: | |
short-name: blocks-listingsandsearch | |
node-version: ${{ needs.config.outputs.node-version }} | |
spec: "cypress/tests/visual/blocks-listingsandsearch.cy.js" | |
visualblocksverticalspacing: | |
uses: ./.github/workflows/visual-acceptance.yml | |
name: Vertical Spacing | |
needs: | |
- config | |
with: | |
short-name: vertical-spacing | |
node-version: ${{ needs.config.outputs.node-version }} | |
spec: "cypress/tests/visual/vertical-spacing.cy.js" | |
visualtypography: | |
uses: ./.github/workflows/visual-acceptance.yml | |
name: Typography | |
needs: | |
- config | |
with: | |
short-name: typography | |
node-version: ${{ needs.config.outputs.node-version }} | |
spec: "cypress/tests/visual/typography.cy.js" |