I just want to run a postman collection with newman which will generate a html-extra report. I get an error message like this :
Running as SYSTEM Building in workspace C:\Users\User.jenkins\workspace\PostmanExecution [PostmanExecution] $ cmd /c call C:\Users\User\AppData\Local\Temp\jenkins4934436003409201261.bat
C:\Users\User.jenkins\workspace\PostmanExecution>newman run Library.postman_collection.json -d TestData.csv -e QA.postman_environment.json -g workspace.postman_globals.json -r htmlextra
Build step 'Execute Windows batch command' marked build as failure
Finished: FAILURE
I can't understand what exactly is the root cause here. The most interesting part is that the html report is being generated at the required location which means the collection is running but the build status is shown as failed.
I just need to get the build status as SUCCESS
The step is likely exiting with an exit code other than 0. If you are sure that there is no error, you can force the script to exit with 0 by adding:
to the end of the step.