-
Notifications
You must be signed in to change notification settings - Fork 0
61 lines (51 loc) · 1.39 KB
/
build-test-report.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
# Build, Test, and Report
name: Build, Test, and Report
on:
pull_request:
branches:
- main
push:
branches:
- main
jobs:
build-n-test:
permissions:
id-token: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '20'
- name: Enable Corepack
run: corepack enable
- name: Set Yarn version
run: yarn set version 4.5.0
- name: Install dependencies
run: yarn install --immutable
- name: Run Build
run: yarn build
- name: Run tests
run: yarn test:coverage
env:
TENDERLY_ACCESS_KEY: ${{ secrets.TENDERLY_ACCESS_KEY }}
PROJECT_SLUG: ${{ secrets.PROJECT_SLUG }}
ACCOUNT_SLUG: ${{ secrets.ACCOUNT_SLUG }}
DEBUG: ${{ github.run_attempt > 1 }}
- name: Upload test results
if: success() || failure()
uses: actions/upload-artifact@v4
with:
name: test-results
path: |
report/
coverage/lcov-report/
retention-days: 15
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v5
with:
directory: ./coverage
token: ${{ secrets.CODECOV_TOKEN }}
# flags: unittests
name: sdk-coverage
fail_ci_if_error: true