-
Notifications
You must be signed in to change notification settings - Fork 9
54 lines (47 loc) · 1.46 KB
/
ci.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
on:
push:
branches: ['master']
pull_request:
branches: [ 'master' ]
env:
NODE_VERSION: '20.x'
jobs:
linux:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
- name: Install dependencies
run: npm ci
- name: Lint
run: npm run lint
# Run tests with
# - Run in band because appears to run more smoothly (avoids memory issues when running in parallel?)
# - Fifteen (!) minute test timeout
# - Force exit to prevent hanging
- name: Run tests
run: npx jest --runInBand --testTimeout=900000 --forceExit
env:
# Tell Node.js how much un-garbage-collected-memory it can
# allow for to prevent it running out (in Mb)
NODE_OPTIONS: --max_old_space_size=14000
# Temporarily skipped
# See https://github.com/stencila/encoda/issues/1080
#- name: Release package
# if: github.ref == 'refs/heads/master'
# run: |
# set -e
# npm ci
# mkdir -p docs
# npx semantic-release
# env:
# GIT_AUTHOR_NAME: Stencila CI Bot
# GIT_AUTHOR_EMAIL: [email protected]
# GIT_COMMITTER_NAME: Stencila CI Bot
# GIT_COMMITTER_EMAIL: [email protected]
# GITHUB_TOKEN: $(GITHUB_TOKEN)
# NPM_TOKEN: $(NPM_TOKEN)