From 81291cbf2b1d2e0c2f67060188c574c9add24760 Mon Sep 17 00:00:00 2001 From: Chris Berkhout Date: Thu, 29 Jul 2021 11:00:29 +0000 Subject: [PATCH] Update .gitlab-ci.yml file --- .gitlab-ci.yml | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 .gitlab-ci.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..e05a7a4 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,23 @@ +image: python:latest + +variables: + PIP_CACHE_DIR: "$CI_PROJECT_DIR/.cache/pip" + POETRY_CACHE_DIR: "$CI_PROJECT_DIR/.cache/poetry" + +cache: + paths: + - .cache/pip + - .cache/poetry + +before_script: + - python -V + - pip install poetry + - poetry install + +test: + script: + - poetry run isort --check + - poetry run black --check + - poetry run pytest + - poetry run coverage run --source=pricehist -m pytest + - poetry run coverage report \ No newline at end of file