Skip to content

Commit 7317e05

Browse files
committed
ci: separate node and browser tests
1 parent 71206d3 commit 7317e05

File tree

2 files changed

+41
-1
lines changed

2 files changed

+41
-1
lines changed
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Verify Browser
2+
3+
on: pull_request
4+
5+
env:
6+
FORCE_COLOR: true
7+
8+
jobs:
9+
verify-linux:
10+
timeout-minutes: 30
11+
name: Verify linux
12+
runs-on: ubuntu-latest
13+
strategy:
14+
matrix:
15+
node-version:
16+
- '18'
17+
18+
steps:
19+
- uses: actions/checkout@v3
20+
21+
- name: Setup Node ${{ matrix.node-version }}
22+
uses: actions/setup-node@v3
23+
env:
24+
FORCE_COLOR: 0
25+
with:
26+
node-version: ${{ matrix.node-version }}
27+
cache: npm
28+
29+
- name: Install Dependencies
30+
run: npm ci
31+
32+
- name: Build packages
33+
run: npm run build
34+
35+
# build for production in CI to make sure tests can run with production build
36+
- name: Build specific packages for production
37+
run: npm run build:production
38+
39+
- name: Test
40+
run: npm run test:browser

.github/workflows/verify-node.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,4 +50,4 @@ jobs:
5050
run: npm run lint
5151

5252
- name: Test
53-
run: npm run test
53+
run: npm run test:node

0 commit comments

Comments
 (0)