Invalid HTTP Status Codes Assertion

Important

The Message Content assertion has been superseded by the Smart Assertion as of ReadyAPI 3.9.0. The assertions will continue to be available, but we recommend transitioning to Smart Assertions.

The Invalid HTTP Status Codes assertion checks whether the target test step received the HTTP result with a status code which is not on the list of defined codes.

Important

This assertion works with test steps that receive HTTP messages.

Availability

This assertion is available in multiple ReadyAPI applications. Depending on the application, it validates the following data:

In...

Checks...

To learn more...

Functional tests

The response HTTP status codes.

See Working With Assertions in Functional Tests.

Security tests

The response HTTP status codes.

See Security Assertions.

Create an assertion

Setting up properties

Specify HTTP codes the target service should not return. To add multiple codes, separate them with a comma.

ReadyAPI: Configuring the Invalid HTTP Status assertion

Example

To cancel the request when there is no content on the page, or it is partial, specify the following codes:

204,206

Other assertions for status codes and headers

Add more assertions for HTTP status codes and response headers:

See Also

Publication date: