-
Notifications
You must be signed in to change notification settings - Fork 3
68 lines (55 loc) · 1.71 KB
/
pr.yaml
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
65
66
67
68
name: PRCI
on: ["pull_request"]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Check out Git repository
uses: actions/checkout@v2
- name: fetch head and set head
run: git fetch -a
- name: Read .nvmrc
run: echo "##[set-output name=NVMRC;]$(cat .nvmrc)"
id: nvm
- name: Set up Node.js
uses: actions/setup-node@v1
with:
node-version: ${{ steps.nvm.outputs.NVMRC }}
- name: yarn install --frozen-lockfile
run: yarn install --frozen-lockfile
- name: run lint
uses: wearerequired/[email protected]
continue-on-error: true
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
eslint: true
auto_fix: true
- name: setup test
run: echo "" > .test.env
- name: initiate mongo
uses: supercharge/[email protected]
with:
mongodb-version: 4.4.2
- name: Load mongo
run: npm run mongoreset -- mongodb://127.0.0.1:27017/database-test
- name: initialize with default configs
run: npm run setup
env:
PORT: 4000
- name: run scripts (nothing should error)
run: >
npm run help:env &&
npm run benchmark &&
npm run mongodump mongodb://127.0.0.1:27017/database-test
- name: run 0 config
run: npm test
- name: run locov
run: npm run locov
env:
MONGODB_URL: mongodb://127.0.0.1:27017/database-test
PORT: 4000
LOGGING_ABSOLUTE: "true"
- name: Coveralls
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}