From 742a9ad72b4f8c2de594265fed3fa43376b308a7 Mon Sep 17 00:00:00 2001 From: Nicolas Arenas Date: Tue, 29 Oct 2024 10:27:12 +0100 Subject: [PATCH] Fix test results --- ogWebconsole/Jenkinsfile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ogWebconsole/Jenkinsfile b/ogWebconsole/Jenkinsfile index e55163c..b9bd17e 100644 --- a/ogWebconsole/Jenkinsfile +++ b/ogWebconsole/Jenkinsfile @@ -39,7 +39,6 @@ pipeline { echo 'Running Tests....' sh ''' cd ogWebconsole - mkdir -p test-results docker run -p 4200:4200 --name oggui-testing -e CHROME_BIN=/usr/bin/chromium -v $(pwd)/karma.conf.js:/app/karma.conf.js -v $(pwd)/.env:/app/.env -d $IMAGE_ID_TESTING docker exec oggui-testing ng test --watch=false --source-map=false --karma-config=karma.conf.js ''' @@ -71,11 +70,12 @@ pipeline { post { always { echo 'Get test results....' + sh "mkdir -p test-results" sh "docker cp oggui-testing:/app/test-results/ogGui-junit-report.xml ./test-results/ogGui-junit-report.xml" - sh "docker stop oggui-testing" - sh "docker rm oggui-testing" junit '**/test-results/*.xml' echo 'Cleaning up....' + sh "docker stop oggui-testing" + sh "docker rm oggui-testing" sh "docker rmi ${IMAGE_ID} || true" sh "docker rmi ${LATEST_ID} || true" sh "docker rmi ${IMAGE_ID_TESTING} || true"