Expected result:
With policyFailureBuildResultPreference: 2 I'd expect the currentBuild.result status to be set to FAILURE and the job to be terminated.
Actual result:
The build status is SUCCESS regardless of scan result and the job continues unhindered
11:45:20 Begin polling Fortify on Demand for results.
11:45:20 1) Poll Status: Queued
11:47:21 2) Poll Status: Completed
11:47:21 Critical: 0
11:47:21 High: 1
11:47:21 Medium: 0
11:47:21 Low: 0
11:47:21 For application status details see the customer portal:
11:47:21 https://emea.fortify.com/Redirect/Releases/12345
11:47:21 Scan failed established policy check
11:47:21 Failure Reason: Pass/Fail Policy requirements not met
Post stage
[Pipeline] script
[Pipeline] {
[Pipeline] echo
11:47:21 SUCCESS
Jenkins version: 2.289.2 LTS Plugin version: 6.1.0
Reproduction steps
Create a pipeline with the following pipeline step:
Results
Expected result: With
policyFailureBuildResultPreference: 2
I'd expect thecurrentBuild.result
status to be set to FAILURE and the job to be terminated.Actual result: The build status is SUCCESS regardless of scan result and the job continues unhindered