dosage/tests/modules/Jenkinsfile

36 lines
1.2 KiB
Plaintext
Raw Normal View History

#!groovy
2022-05-27 23:19:19 +00:00
node {
stage('Checkout') {
deleteDir()
checkout scm
}
stage ('Run tests') {
timeout(time: 12, unit: 'HOURS') {
withCredentials([string(credentialsId: 'proxymap', variable: 'PROXYMAP')]) {
2023-10-26 23:38:58 +00:00
sh 'podman run --rm -v $PWD:/work --userns=keep-id docker.io/python:3.12-bookworm /work/tests/modules/testall.sh'
}
}
}
2022-05-27 23:19:19 +00:00
stage('Report') {
junit 'junit.xml'
2023-10-26 20:25:25 +00:00
recordCoverage sourceCodeEncoding: 'UTF-8', tools: [
[parser: 'COBERTURA', pattern: 'coverage.xml']
]
}
2020-11-23 00:18:17 +00:00
stage('Allure Report') {
copyArtifacts filter: 'allure-history.zip', optional: true,
projectName: JOB_NAME, selector: lastWithArtifacts()
if (fileExists('allure-history.zip')) {
unzip dir: 'allure-data', quiet: true, zipFile: 'allure-history.zip'
sh 'rm -f allure-history.zip'
2020-11-23 00:18:17 +00:00
}
2022-05-27 23:19:19 +00:00
sh 'podman run --rm -v $PWD:/work --userns=keep-id docker.io/tobix/allure-cli generate allure-data'
zip archive: true, dir: 'allure-report', glob: 'history/**', zipFile: 'allure-history.zip'
publishHTML reportDir: 'allure-report', reportFiles: 'index.html', reportName: 'Allure Report'
}
}