1+ default :
2+ image : python:3.7
3+ before_script :
4+ - echo ===== update pip =====
5+ - python -m pip install -U pip
6+ - echo ===== install tox =====
7+ - pip install tox
8+
19stages :
210 - pytest
311 - quality
@@ -13,16 +21,9 @@ cache:
1321
1422pytest :
1523 stage : pytest
16- image : python:3.7
17- # several python versions in 1 image: quay.io/python-devs/ci-image
18- before_script :
19- - echo ===== update pip =====
20- - python -m pip install -U pip
21- - echo ===== install tox =====
22- - pip install tox
24+ script :
2325 - echo ===== create folder for artifacts =====
2426 - mkdir test-reports
25- script :
2627 - tox -e py
2728 artifacts :
2829 when : always
@@ -35,48 +36,25 @@ pytest:
3536black :
3637 stage : quality
3738 image : python:3.7
38- before_script :
39- - echo ===== update pip =====
40- - python -m pip install -U pip
41- - echo ===== install tox =====
42- - pip install tox
4339 script :
4440 - tox -e black
4541
4642mypy :
4743 stage : quality
48- image : python:3.7
49- before_script :
50- - echo ===== update pip =====
51- - python -m pip install -U pip
52- - echo ===== install tox =====
53- - pip install tox
5444 script :
5545 - tox -e mypy
5646
5747docs :
5848 stage : quality
59- image : python:3.7
60- before_script :
61- - echo ===== update pip =====
62- - python -m pip install -U pip
63- - echo ===== install tox =====
64- - pip install tox
6549 script :
6650 - tox -e docs
6751
6852pytest-main :
6953# run test using directly the pytest main branch
7054 stage : pytest
71- image : python:3.7
72- before_script :
73- - echo ===== update pip =====
74- - python -m pip install -U pip
75- - echo ===== install tox =====
76- - pip install tox
55+ script :
7756 - echo ===== create folder for artifacts =====
7857 - mkdir test-reports
79- script :
8058 - tox -e pytest-main
8159 artifacts :
8260 when : always
@@ -89,12 +67,12 @@ pytest-main:
8967 - if : $CI_PIPELINE_SOURCE == "schedule"
9068
9169sonar :
70+ image : sonarsource/sonar-scanner-cli
9271 stage : sonar
72+ before_script : []
9373 variables :
9474 SONAR_HOST_URL : $INS_SONAR_URL
9575 SONAR_LOGIN : $INS_SONAR_LOGIN
96- image :
97- name : sonarsource/sonar-scanner-cli
9876 script :
9977 - sonar-scanner -Dsonar.projectKey=$CI_PROJECT_NAME -Dsonar.branch.name=$CI_BUILD_REF_NAME -Dsonar.python.coverage.reportPaths=test-reports/coverage.xml
10078 allow_failure : true
0 commit comments