Checks

Get introduced to checks.

In the previous lesson, we learned about scenarios. In this lesson, we will learn about checks.

What are checks?

Checks validate the response received from the server and save it to the user session if needed. We can apply multiple checks on the same response.

checks provide a DSL for chaining the following steps:

Note: It is not necessary to have all these steps. Defining check is the only mandatory step.

Types of checks

Here we define what kind of check we want to perform. The following table shows the different types of checks that Gatling provides:

Type Description
status HTTP status code
currentLocation absolute URL of the current page
currentLocationRegex(pattern) extract part of the URL using the given regular expression from the absolute URL of the current page
...