-
Notifications
You must be signed in to change notification settings - Fork 126
64 lines (52 loc) · 1.57 KB
/
pull-request-tests.yml
File metadata and controls
64 lines (52 loc) · 1.57 KB
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
name: PR Tests
# Only run on non-draft PRs, and when PRs are synched
on:
pull_request:
types: [opened, reopened, ready_for_review, synchronize]
# If the PR has other files, a push w/ just .md or /docs
# files will still cause tests to run
paths-ignore:
- "**.md"
- "docs/**"
jobs:
build:
if: github.event.pull_request.draft == false
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
node: [22, 24]
steps:
- uses: actions/checkout@v6
- uses: actions/setup-node@v6
with:
node-version: ${{ matrix.node }}
- name: Install Dependencies
run: npm ci
- name: Install Playwright Browsers
run: npx playwright install --with-deps
- name: Build
run: npm run build
# Generate doc to ensure that there are no warnings/errors
- name: Generate TypeDoc
run: npm run typedoc
- name: Lint
run: npm run lint
- name: Test in CI
run: npm run test:ci
- name: Code Coverage Summary Report
uses: irongut/CodeCoverageSummary@v1.3.0
with:
filename: coverage/**/cobertura-coverage.xml
badge: true
fail_below_min: true
format: markdown
output: both
thresholds: "100 100"
- name: Add Coverage PR Comment
uses: marocchino/sticky-pull-request-comment@v3
if: github.event_name == 'pull_request' && matrix.node == 22
with:
recreate: true
path: code-coverage-results.md