-
Notifications
You must be signed in to change notification settings - Fork 2
/
.gitlab-ci.yml
59 lines (50 loc) · 1.03 KB
/
.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
image: python
variables:
GIT_SUBMODULE_STRATEGY: recursive
default:
# Columns of the pipeline
stages:
- build
- test
- deploy
# test installation
install:
stage: build
before_script:
- pip install -r requirements.txt
script:
- pip install .
# Static code analysis job via Pylint
static analysis:
stage: test
before_script:
- pip install pylint
- pip install -r requirements.txt
script:
- pylint bdld
allow_failure: true
# run all unittests
unittests:
stage: test
before_script:
- pip install -r requirements.txt
script:
- python3 -m unittest discover
# code coverage reporting
module tests:
stage: test
before_script:
- pip install coverage
- pip install -r requirements.txt
script:
- coverage run -m unittest discover > /dev/null
- coverage report
coverage: /\d+\%\s*$/
# Test building package (make package)
package:
stage: deploy
before_script:
- pip install wheel
- pip install -r requirements.txt
script:
- python setup.py sdist bdist_wheel