Created
December 12, 2024 10:03
-
-
Save borodicht/50bbd23e34b8f8150d833cf8c74ad0b8 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pipeline { | |
agent any | |
tools { | |
// Install the Maven version configured as "M3" and add it to the path. | |
maven "M3" | |
} | |
stages { | |
stage('Test') { | |
steps { | |
// Get some code from a GitHub repository | |
git 'https://github.com/borodichtimofei/SaucedemoHSE.git' | |
// Run Maven on a Unix agent. | |
sh "mvn -Dmaven.test.failure.ignore=true clean package" | |
// To run Maven on a Windows agent, use | |
// bat "mvn -Dmaven.test.failure.ignore=true clean package" | |
} | |
post { | |
// If Maven was able to run the tests, even if some of the test | |
// failed, record the test results and archive the jar file. | |
success { | |
junit '**/target/surefire-reports/TEST-*.xml' | |
} | |
} | |
} | |
stage('Allure') { | |
steps { | |
script { | |
allure([ | |
includeProperties: false, | |
jdk: '', | |
properties: [], | |
reportBuildPolicy: 'ALWAYS', | |
results: [[path: 'target/allure-results']] | |
]) | |
} | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment