-
Notifications
You must be signed in to change notification settings - Fork 2
43 lines (43 loc) · 1.27 KB
/
tests.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
name: Tests CI
on: [push, workflow_dispatch]
jobs:
static-eslint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- run: npm install
- run: npm run lint
unit-integration-jest:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Run jest
uses: actions/setup-node@v1
with:
node-version: '12'
- run: npm install
- run: npm test
ui-cypress-percy-chrome:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
# Install NPM dependencies, cache them correctly
# and run all Cypress tests
- name: Cypress Run
uses: cypress-io/[email protected]
with:
browser: chrome
headless: true
record: true
projectId: ${{ secrets.CY_DASHBOARD_ID }}
build: npm run generate
start: npm run start
# wait-on: 'http://localhost:3000'
env:
CYPRESS_PROJECT_ID: ${{ secrets.CYPRESS_PROJECT_ID }}
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
- name: Percy Test
run: npx percy exec -- cypress run --browser chrome --headless --env percy=treu,grep=visual
env:
PERCY_TOKEN: ${{ secrets.PERCY_TOKEN }}