There are scenarios where you might need to stop a test execution.
There are 3 ways to do that.
1. From the Results page
The easiest option is to click on the
Stop Test button from the Results page.
Deleting a test execution which is in progress will also stop it.
2. From inside the test
You can add a
Stop Test step directly in your test.
Stop Test option is inside the
A good practice is to add that step inside an
For example, if you want to automatically stop a test at a certain point if you have more than 3 failed assertions, you can use a
Variable Condition in your
If Statement and check if the system variable
$systemFailedCounter is greater than 3.
You can find more details about system variables in the Variables chapter.
3. With the Endtest API
You can stop a test execution with the Endtest API by using the
The unique hash for that test execution must also be provided.
More details are available in the Endtest API chapter.