Why HTTP responses with 500 and 404 status codes are marked as 'passed'?
I am trying to use ReadyAPI to run basic functional tests but they are marked as PASSED even when the HTTP response status codes are 500 or 404, which I find strange to say the least. All responses which have 5xx or 4xx status codes should be marked as FAILED - but I do not seem to be able to find a way to do that for all test cases in one go - is there any way to do that?
ReadyAPI does not automatically class a 404 or 500 as a fail, you need to tell ReadyAPI what to do.
You need to add an assertion to each service call. There are various assertions you can apply to a test step. E.g. check for specific content. There are also assertions for status codes; Invalid Status Codes and Valid Status Codes.
I usually do this...
In the valid service codes assertion, I put "200".
In the invalid service codes assertion, I put "404, 500"