-
-
Notifications
You must be signed in to change notification settings - Fork 125
110 lines (104 loc) · 3.02 KB
/
ci.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
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
name: CI
on:
push:
branches: [main]
pull_request:
types: [opened, synchronize]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
name: Test on (Node ${{ matrix.version }})
strategy:
fail-fast: false
matrix:
version: [18.17.0, 20.8.0, 22.7.0]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
- uses: actions/setup-node@v3
with:
node-version: ${{ matrix.version }}
cache: 'pnpm'
cache-dependency-path: '**/pnpm-lock.yaml'
- run: pnpm install --frozen-lockfile
- run: pnpm test
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
- uses: actions/setup-node@v3
with:
node-version: 18
cache: 'pnpm'
cache-dependency-path: '**/pnpm-lock.yaml'
- run: pnpm install --frozen-lockfile
- run: pnpm run compile
- uses: actions/upload-artifact@v4
with:
name: create-waku
path: |
packages/create-waku
!packages/create-waku/node_modules
if-no-files-found: error
- uses: actions/upload-artifact@v4
with:
name: waku
path: |
packages/waku
!packages/waku/node_modules
if-no-files-found: error
e2e:
name: E2E on ${{ matrix.os }} (Node ${{ matrix.version }}) - (${{ matrix.shared }}/4)
needs:
- build
strategy:
fail-fast: false
matrix:
shared: [1, 2, 3, 4]
shardTotal: [4]
os: [ubuntu-latest, windows-latest, macos-latest]
version: [18.17.0, 20.8.0, 22.7.0]
exclude:
- os: macos-latest
version: 18.17.0
- os: macos-latest
version: 20.8.0
- os: windows-latest
version: 18.17.0
- os: windows-latest
version: 20.8.0
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
- uses: actions/setup-node@v3
with:
node-version: ${{ matrix.version }}
cache: 'pnpm'
cache-dependency-path: '**/pnpm-lock.yaml'
- run: pnpm install --frozen-lockfile
- uses: actions/download-artifact@v4
with:
name: create-waku
path: packages/create-waku
- uses: actions/download-artifact@v4
with:
name: waku
path: packages/waku
- name: Install Playwright
id: install-playwright
uses: ./.github/actions/playwright
- run: pnpm exec playwright test --shard=${{ matrix.shared }}/${{ matrix.shardTotal }}
env:
TEMP_DIR: ${{ runner.temp }}
- uses: actions/upload-artifact@v3
if: always()
with:
name: playwright-report-${{ matrix.os }}-${{ matrix.version }}-${{ matrix.shared }}
path: test-results/
retention-days: 30
if-no-files-found: ignore