-
Notifications
You must be signed in to change notification settings - Fork 2
/
.gitlab-ci.yml
60 lines (56 loc) · 974 Bytes
/
.gitlab-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
55
56
57
58
59
60
stages:
- init
- tests
- build
node_modules:
stage: init
image: node:10.12.0-alpine
tags:
- staging
cache:
key: '$CI_PROJECT_ID'
paths:
- node_modules/
artifacts:
paths:
- node_modules/
expire_in: 4 hrs
script:
- npm i
lint:
stage: tests
image: node:10.12.0-alpine
tags:
- staging
dependencies:
- node_modules
script:
- npm run lint
integration tests:
stage: tests
image: node:10.12.0-alpine
tags:
- staging
dependencies:
- node_modules
artifacts:
paths:
- coverage/.
expire_in: 4 week
name: 'coverage-${CI_BUILD_REF_NAME}_${CI_BUILD_REF}'
coverage: '/^All files\s+\|\s+\d+\.*\d*\s+\|\s*(\d+\.*\d*)/'
script:
- npm run test:cover -- --detectOpenHandles
build:
stage: build
image: node:10.12.0-alpine
tags:
- staging
dependencies:
- node_modules
artifacts:
paths:
- dist/
expire_in: 4 hrs
script:
- npm run build