-
Notifications
You must be signed in to change notification settings - Fork 325
70 lines (56 loc) · 1.64 KB
/
tests_and_lint.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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
name: Tests and Lint
on:
push:
branches:
- unstable
- 'v[0-9].x-[0-9]+-[0-9]+'
- 'v[0-9].[0-9].x-[0-9]+-[0-9]+'
pull_request:
branches:
- unstable
- 'v[0-9].x-[0-9]+-[0-9]+'
- 'v[0-9].[0-9].x-[0-9]+-[0-9]+'
concurrency:
group: hydrogen-${{ github.head_ref }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
runs-on: ${{ matrix.os }}
timeout-minutes: 30
strategy:
matrix:
# os: [windows-latest, ubuntu-latest]
os: [ubuntu-latest]
node-version: [16.x, 18.x]
name: OS ${{ matrix.os }} / NodeJS ${{ matrix.node-version }}
steps:
- name: Checkout the code
uses: actions/checkout@v2
- name: Setup Node.js
uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node-version }}
cache: 'yarn'
- name: Install the packages
# Bump yarn timeout to fix an issue with Windows CI downloading the Playwright/Chromium stuff
run: yarn install --frozen-lockfile --ignore-engines --network-timeout 36000
- name: Build the code
run: yarn build --force
- name: Check formatting
run: yarn format:check
- name: Lint the framework code
run: yarn lint
- name: Lint the template code
run: yarn lint
working-directory: ./templates/demo-store
- name: Run the unit tests
run: yarn test
- name: Run the E2E tests
run: yarn test-e2e
env:
CI: true
- name: Run template E2E tests
run: yarn test:ci
working-directory: ./templates/demo-store
env:
CI: true