Add allure report for module tests

This commit is contained in:
Tobias Gruetzmacher 2020-11-23 01:18:17 +01:00
parent bcc7f83ef8
commit 30db5120f1

View file

@ -23,7 +23,12 @@ def runTests() {
}
stage ('Run tests') {
withCredentials([string(credentialsId: 'proxymap', variable: 'PROXYMAP')]) {
sh "TESTALL=1 py.test -v --cov=dosagelib --cov-report xml --tb=short -n10 --junitxml=junit.xml tests/modules/check_comics.py || true"
sh '''
TESTALL=1 py.test -v --cov=dosagelib --cov-report xml \
--alluredir=allure-data \
--tb=short -n10 --junitxml=junit.xml \
tests/modules/check_comics.py || true
'''
}
}
stage('Report') {
@ -43,6 +48,11 @@ ansiColor('xterm') {
img.inside {
runTests()
}
stage('Allure Report') {
sh 'docker run --rm -v $PWD:/work tobix/allure-cli generate allure-data'
publishHTML reportDir: 'allure-report', reportFiles: 'index.html', reportName: 'Allure Report'
}
}
}