diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..654cea2 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,21 @@ +stages: + - test + +test: + stage: test + image: python:3.11-bookworm + variables: + DJANGO_SETTINGS_MODULE: foerderbarometer.settings + ENVIRONMENT: test + SECRET_KEY: this-is-not-a-secret-key + DATABASE_ENGINE: sqlite3 + OAUTH_ENABLED: no + tags: + - docker + coverage: /(?i)total.*? (100(?:\.0+)?\%|[1-9]?\d(?:\.\d+)?\%)$/ + before_script: + - pip install -r requirements.txt coverage + script: + - coverage run manage.py test --noinput + after_script: + - coverage report