Last active
July 25, 2016 16:15
-
-
Save jay-johnson/d9163509517eee84834d49c93144f05d to your computer and use it in GitHub Desktop.
Determine Test Results - Do the results == expected results?
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
// Now validate the results match the expected results | |
stage "Test(${test_num}) - Validate Results" | |
test_results = readFile '/tmp/test_results' | |
echo "Test(${test_num}) Results($test_results) == Expected(${expected_results})" | |
sh "if [ \"${test_results}\" != \"${expected_results}\" ]; then echo \" --------------------- Test(${test_num}) Failed--------------------\"; echo \" - Test(${test_num}) Failed\"; echo \" - Test(${test_num}) Failed\";exit 1; else echo \" - Test(${test_num}) Passed\"; exit 0; fi" | |
echo "Done Running Test(${test_num})" | |
// cleanup after the test run | |
sh "rm -f /tmp/test_results" | |
currentBuild.result = 'SUCCESS' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment