Open History to see the last commit
1name: pr
2on: [pull_request]
3jobs:
4 test:
5 name: 'Node ${{ matrix.node }}, React ${{ matrix.react }}'
6 runs-on: ubuntu-latest
7 strategy:
8 matrix:
9 node: [16.14.2]
10 react: [17, 18]
11 steps:
12 - uses: actions/checkout@v2
13 - uses: actions/setup-node@v2
14 with:
15 node-version: ${{ matrix.node }}
16 - name: Install dependencies
17 uses: bahmutov/npm-install@v1
18 with:
19 install-command: npm install
20 - run: |
21 npm run test:ci
22 npm run test:size
23 if: matrix.react == '18'
24 env:
25 REACTJS_VERSION: ${{ matrix.react }}
26 BUNDLEWATCH_GITHUB_TOKEN: ${{ secrets.BUNDLEWATCH_GITHUB_TOKEN }}
27 - run: npm run test:jest
28 if: matrix.react == '17'
29 env:
30 REACTJS_VERSION: ${{ matrix.react }}
31 - name: Upload coverage to Codecov
32 uses: codecov/codecov-action@v2