-
Notifications
You must be signed in to change notification settings - Fork 19
52 lines (44 loc) · 1.3 KB
/
auto-build.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
44
45
46
47
48
49
50
51
52
name: CI / Automated testing
on:
pull_request:
branches:
- '**'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
install-deps:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install deps
uses: ./.github/workflows/composite/npm
build-and-test:
runs-on: ubuntu-latest
needs: install-deps
strategy:
fail-fast: false
matrix:
target: ['lint', 'format', 'build', 'test', 'e2e']
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install deps
uses: ./.github/workflows/composite/npm
- name: Execute ${{ matrix.target }} npm script
if: ${{ matrix.target != 'e2e' }}
run: npm run ${{ matrix.target }}
- name: Execute e2e npm script
if: ${{ matrix.target == 'e2e' }}
uses: cypress-io/github-action@v6
timeout-minutes: 10
with:
wait-on: 'http://localhost:8080/'
wait-on-timeout: 120
start: npm start
browser: chrome
record: ${{ github.repository == 'NeuraLegion/cypress-har-generator' }}
env:
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}