aboutsummaryrefslogtreecommitdiff
path: root/.gitlab-ci.yml
diff options
context:
space:
mode:
authorgabrielgio <gabriel.giovanini@pm.me>2021-07-18 20:19:44 +0200
committergabrielgio <gabriel.giovanini@pm.me>2021-07-18 20:19:44 +0200
commit1f3e0496079ec2e57842b3abb7aea1630bf47f9e (patch)
tree2836a3a8c0478a974c641de81c16f0b3ce8bd6a3 /.gitlab-ci.yml
parent68414b21fb57c06e8b03c1efba06b570a8cea5be (diff)
downloadreddit-nextcloud-importer-1f3e0496079ec2e57842b3abb7aea1630bf47f9e.tar.gz
reddit-nextcloud-importer-1f3e0496079ec2e57842b3abb7aea1630bf47f9e.tar.bz2
reddit-nextcloud-importer-1f3e0496079ec2e57842b3abb7aea1630bf47f9e.zip
ref: Split test and coverage
Split `test` into two different jobs: `test` and `coverage`.
Diffstat (limited to '.gitlab-ci.yml')
-rw-r--r--.gitlab-ci.yml12
1 files changed, 11 insertions, 1 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 795dbfb..a951333 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -3,6 +3,7 @@ stages:
- build
docker-build-master:
+ needs: [ "test", "coverage" ]
image: docker:latest
stage: build
services:
@@ -17,6 +18,7 @@ docker-build-master:
- master
docker-build:
+ needs: [ "test", "coverage" ]
image: docker:latest
stage: build
services:
@@ -37,9 +39,17 @@ test:
script:
- pip install -r dev-requirements.txt
- pytest -n 4 --junitxml=report.xml
+ artifacts:
+ reports:
+ junit: report.xml
+
+coverage:
+ image: python:3-alpine
+ stage: test
+ script:
+ - pip install -r dev-requirements.txt
- coverage run -m pytest
- coverage xml -o cobertura.xml
artifacts:
reports:
cobertura: cobertura.xml
- junit: report.xml