-
Notifications
You must be signed in to change notification settings - Fork 90
53 lines (45 loc) · 1.39 KB
/
Copy pathci.yml
File metadata and controls
53 lines (45 loc) · 1.39 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
name: Continuous Integration
on:
push:
branches:
- '*'
pull_request:
branches:
- master
permissions:
contents: read
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
# Run the full suite behind UTC, at UTC and ahead of UTC so that
# timezone-dependent date handling bugs can't slip through
timezone: [ 'America/Toronto', 'UTC', 'Asia/Kolkata' ]
name: "CI job (timezone: ${{ matrix.timezone }})"
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v7
with:
node-version: 24
cache: 'npm'
- name: Install dependencies
run: npm ci
# Note: must come *after* npm ci, as that step removes node_modules entirely
- name: Cache Vite dependency optimizer output
uses: actions/cache@v6
with:
path: node_modules/.vite
key: vite-deps-${{ runner.os }}-${{ hashFiles('package-lock.json', 'vite.config.ts') }}
restore-keys: |
vite-deps-${{ runner.os }}-
- name: Run tests with coverage
run: npm run test:coverage
env:
TZ: ${{ matrix.timezone }}
- name: Coveralls
# coverage is identical in all timezones, upload it only once
if: matrix.timezone == 'UTC'
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}