Skip to content

Set up Playwright for e2e tests, add landing page e2e tests #126

Set up Playwright for e2e tests, add landing page e2e tests

Set up Playwright for e2e tests, add landing page e2e tests #126

Workflow file for this run

# This workflow will do a clean install of node dependencies, cache/restore them, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
name: Node.js CI
on:
push:
branches: [ develop ]
pull_request:
jobs:
lint:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: npm ci
- run: npm run lint
- run: npm run build
unit-tests:
# Lint is fast. If we wait for it we guarantee a cache hit on dependencies.
needs: lint
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: npm ci
- run: npm test
e2e-tests:
# Lint is fast. If we wait for it we guarantee a cache hit on dependencies.
needs: lint
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
env:
WAIT_ON_TIMEOUT: 600000
steps:
- uses: actions/checkout@v2
with:
submodules: 'true'
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: docker compose -f e2e_test_stack/docker-compose.yml build
- run: docker compose -f e2e_test_stack/docker-compose.yml pull
- run: npm ci
- run: npm run e2e:once