-
Notifications
You must be signed in to change notification settings - Fork 0
43 lines (35 loc) · 1005 Bytes
/
unit-tests.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
name: Unit Tests
on:
push:
branches:
- '**'
pull_request:
branches:
- '**'
jobs:
test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
timezone: [UTC, America/Los_Angeles, Europe/Berlin, Australia/Sydney]
steps:
- uses: actions/checkout@v4
- name: Node 20
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'npm'
- name: Write .npmrc file
run: |
echo //npm.pkg.github.com/:_authToken=${{ secrets.GITHUB_TOKEN }} > $HOME/.npmrc
echo @rundown-studio:registry=https://npm.pkg.github.com >> $HOME/.npmrc
- name: Install Dependencies
run: npm ci --loglevel=error
- name: Compile Typescript
run: npm run build
- name: Run Tests
run: npm run test:ci 2>&1 | tee $GITHUB_STEP_SUMMARY; exit ${PIPESTATUS[0]}
env:
TZ: ${{ matrix.timezone }}
NODE_OPTIONS: --experimental-vm-modules