-
Notifications
You must be signed in to change notification settings - Fork 1
52 lines (48 loc) · 1.44 KB
/
on_push.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: React Timing Hooks – Build & Test
on: [push, pull_request]
jobs:
build:
name: ${{ matrix.os }}, Node ${{ matrix.node-version }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-latest, windows-latest, ubuntu-latest]
node-version: [16.x, 18.x, 20.x]
steps:
- uses: actions/checkout@v1
- name: Setup Node ${{ matrix.node-version }} on ${{ matrix.os }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: npm install
run: npm ci
- name: install locales for integration tests
run: |
npm install -g full-icu
echo "NODE_ICU_DATA=`node-full-icu-path 2>/dev/null`" >> $GITHUB_ENV
shell: bash
- name: Lint and unit tests
run: |
npm run prettier:check
npm run test:unit
- name: Coveralls.io Test Coverage
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
flag-name: run-${{ matrix.node-version }}-on-${{ matrix.os }}
parallel: true
- name: Integration tests
run: |
npm run build --if-present
npm run test:integration
env:
CI: true
finish:
needs: build
runs-on: ubuntu-latest
steps:
- name: Coveralls Finished
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.github_token }}
parallel-finished: true