From fb260a0f6d055e16740528a11e53bc3359cbdd19 Mon Sep 17 00:00:00 2001 From: Marcin-Ramotowski Date: Sat, 3 May 2025 20:21:02 +0000 Subject: [PATCH] Corrected directory in jenkins pipeline --- Jenkinsfile | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index b2144be..f286028 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -14,13 +14,15 @@ pipeline { stage('Test python app') { steps { script { - sh ''' - python3 -m venv env - env/bin/pip install -r requirements.txt pytest - env/bin/pytest . --junit-xml=pytest_junit.xml - ''' + dir('api') { + sh ''' + python3 -m venv env + env/bin/pip install -r requirements.txt pytest + env/bin/pytest . --junit-xml=pytest_junit.xml + ''' } } + } post { always { junit testResults: '**/*pytest_junit.xml'