-
Notifications
You must be signed in to change notification settings - Fork 4
/
.gitlab-ci.yml
62 lines (57 loc) · 1.4 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
60
61
62
stages:
- build
- test
- post-test
- release
include:
- 'https://ci-files.skypicker.com/templates/build/coala.yml'
- 'https://ci-files.skypicker.com/templates/build/tox_init.yml'
- 'https://ci-files.skypicker.com/templates/build/zoo.yml'
- 'https://ci-files.skypicker.com/templates/build/black.yml'
black:
script:
- black -l 120 --check --fast docs kw test setup.py
- black -l 120 --check --py36 kw/cache/aio.py
tests:
stage: test
image: kiwicom/tox
dependencies:
- tox_init
services:
- redis
script:
- export TEST_REDIS_URL=redis://$REDIS_PORT_6379_TCP_ADDR
- TOX_SKIP_ENV="coverage-report|coala" tox
artifacts:
paths:
- reports/
- .coverage*
tox_tests_coverage:
extends: tests
stage: post-test
dependencies:
- tox_init
- tests
needs:
- tox_init
- tests
before_script:
- mkdir -p $CI_PROJECT_DIR/coverage-reports
artifacts:
paths:
- coverage-reports/
script:
- tox -e coverage-report -- -o $CI_PROJECT_DIR/coverage-reports/coverage-integration.xml
pages:
stage: release
image: python:3.7-alpine
script:
- apk add --no-cache make gcc build-base
- pip install -r requirements.txt -r test-requirements.txt -r docs-requirements.txt -e .
- sphinx-apidoc --output-dir docs/kw --no-toc kw && make --directory=docs html
- mv docs/_build/html public
artifacts:
paths:
- public
only:
- master