-
Notifications
You must be signed in to change notification settings - Fork 1
/
.gitlab-ci.yml
59 lines (49 loc) · 960 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
variables:
PIP_CACHE_DIR: "${CI_PROJECT_DIR}/.cache/pip"
cache:
key: "pypads-onto-${CI_JOB_NAME}"
paths:
- .cache/pip
- .venv
stages:
- tests
# - deploy
# Jobs templates
.install-deps-template: &install-deps
before_script:
- pip install poetry
- poetry --version
- poetry config virtualenvs.in-project true
- poetry install --verbose
#.deploy-template: &deploy
# <<: *install-deps
# image: python:3.8
# stage: deploy
.test-template: &test
<<: *install-deps
stage: tests
coverage: '/TOTAL.*\s(\d+\.\d+\%)/'
script:
- poetry run pytest test/
artifacts:
paths:
- tests/logs
when: always
expire_in: 1 week
# Test with different python versions
test-python-3.6:
<<: *test
image: python:3.6
test-python-3.7:
<<: *test
image: python:3.7
test-python-3.8:
<<: *test
image: python:3.8
## Deploy jobs
#publish:
# <<: *deploy
# only:
# - tags
# script:
# - poetry publish