2021-01-28 22:39:17 +01:00
|
|
|
name: E2E
|
2021-01-28 22:36:18 +01:00
|
|
|
|
|
|
|
on: [push, pull_request]
|
|
|
|
|
2022-04-25 23:38:27 +00:00
|
|
|
permissions:
|
|
|
|
contents: read
|
|
|
|
|
2021-01-28 22:36:18 +01:00
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
strategy:
|
2022-09-21 10:36:38 +05:30
|
|
|
fail-fast: false
|
2021-01-28 22:36:18 +01:00
|
|
|
matrix:
|
2021-07-15 12:27:21 +02:00
|
|
|
node-version: [16.x]
|
2022-09-21 10:42:27 +05:30
|
|
|
containers: [1, 2, 3, 4]
|
2021-01-28 22:36:18 +01:00
|
|
|
steps:
|
2022-09-14 04:12:45 +01:00
|
|
|
- uses: actions/checkout@v3
|
2021-01-28 22:36:18 +01:00
|
|
|
|
2022-09-21 10:36:38 +05:30
|
|
|
- uses: actions/cache@v3
|
|
|
|
id: yarn-and-build-cache
|
|
|
|
with:
|
|
|
|
path: |
|
|
|
|
~/.cache/Cypress
|
|
|
|
build
|
|
|
|
node_modules
|
|
|
|
key: ${{ runner.os }}-node_modules-build-${{ hashFiles('**/yarn.lock') }}
|
|
|
|
restore-keys: |
|
|
|
|
${{ runner.os }}-node_modules-build-
|
|
|
|
|
2022-09-14 04:12:45 +01:00
|
|
|
- name: Setup Node.js ${{ matrix.node-version }}
|
|
|
|
uses: actions/setup-node@v3
|
|
|
|
with:
|
|
|
|
cache: yarn
|
|
|
|
node-version: ${{ matrix.node-version }}
|
2021-01-28 22:36:18 +01:00
|
|
|
|
2022-09-21 10:36:38 +05:30
|
|
|
# Install NPM dependencies, cache them correctly
|
|
|
|
# and run all Cypress tests
|
|
|
|
- name: Cypress run
|
|
|
|
uses: cypress-io/github-action@v3
|
|
|
|
with:
|
|
|
|
start: yarn dev
|
|
|
|
wait-on: 'http://localhost:9000'
|
|
|
|
record: true
|
|
|
|
headless: true
|
|
|
|
parallel: true
|
2022-09-14 04:12:45 +01:00
|
|
|
env:
|
2022-09-21 10:36:38 +05:30
|
|
|
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
|