Skip to content
This repository was archived by the owner on Apr 15, 2025. It is now read-only.

Commit 12259d3

Browse files
author
williamd5
committed
github workflow for tests
1 parent e5469a2 commit 12259d3

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed

.github/workflows/test.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Unit tests
2+
'on':
3+
pull_request:
4+
types:
5+
- opened
6+
- synchronize
7+
- reopened
8+
schedule:
9+
- cron: '0 6 * * 0'
10+
11+
jobs:
12+
test:
13+
name: 'Node.js v${{ matrix.node }}'
14+
runs-on: ubuntu-latest
15+
strategy:
16+
matrix:
17+
node:
18+
- 18
19+
- 16
20+
steps:
21+
- uses: actions/setup-node@v1
22+
with:
23+
node-version: '${{ matrix.node }}'
24+
- uses: actions/checkout@v2
25+
- name: 'Cache node_modules'
26+
uses: actions/cache@v2
27+
with:
28+
path: ~/.npm
29+
key: ${{ runner.os }}-node-v${{ matrix.node }}-${{ hashFiles('**/package.json') }}
30+
restore-keys: |
31+
${{ runner.os }}-node-v${{ matrix.node }}-
32+
- name: Install Dependencies
33+
run: npm install
34+
- name: Run All Node.js Tests
35+
run: npm run test

0 commit comments

Comments
 (0)