Skip to content

Commit

Permalink
Use more generic gitlab-ci.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
m-bucher authored and sbernhard committed Jun 26, 2024
1 parent ea215aa commit ec3c608
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,22 +5,25 @@ stages:

variables:
PYTHON_VERSION: "3.11"
PYTHON_IMAGE: "${CI_DEPENDENCY_PROXY_GROUP_IMAGE_PREFIX}/python:${PYTHON_VERSION}-alpine3.18"
PYTHON_IMAGE: "python:${PYTHON_VERSION}"


.common:
image: ${PYTHON_IMAGE}
before_script:
- pip install -r test_requirements.txt
- pip freeze > test_requirements.freeze
- python --version

python:
extends: .common
stage: lint
image: "${PYTHON_IMAGE}"
script:
- pip install -r test_requirements.txt
- flake8 .

unittest:
extends: .common
stage: test
image: "${PYTHON_IMAGE}"
before_script:
- pip install -r test_requirements.txt
- pip freeze > test_requirements.freeze
- python --version
script:
- pytest tests
- coverage run --source errata_server `which pytest` tests
Expand Down

0 comments on commit ec3c608

Please sign in to comment.