diff --git a/Jenkinsfile b/Jenkinsfile index f54e1be..7c53c34 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -28,9 +28,13 @@ pipeline { docker { image "python:$PY_VERSION" args '-e DJANGO_SETTINGS_MODULE="locallibrary.settings"'} } + environment { + PY_ENV = "/tmp/pitestenv" + } steps { sh ''' - python3 -m venv /tmp/pitestenv; source /tmp/pitestenv/bin/activate + python -m venv ${PY_ENV}; source ${PY_ENV}/bin/activate + export PATH=${PY_ENV}/bin:${PATH} pip install -r requirements.txt python -m pytest catalog/tests/ python -m xmlrunner discover -p *_test.py