Previously, to fix a broken test object, you need to manually reproduce the state of the application under test (AUT) on failure. This approach is time-consuming. With automated tests using a Data-driven testing framework, it is even more tedious, complicated, and exhausting to reproduce the exact state of AUT manually when there is a large amount of test data.
To tackle this issue, Katalon Studio 7.8.0 supports restoring the AUT to the state when the test fails due to locators not finding Web UI objects. This powerful capability allows you to open a "Time Capsule" for fixing broken objects, reducing reproduction effort, and cutting off time spent on troubleshooting and maintaining your test scripts.
Notably, two enhancements assist you in optimizing the workflow of fixing your tests:
- The test engine captures the snapshot (in HTML) of your AUT upon failures automatically. The snapshot stored in the Report folder of a project allows you to time-travel to the AUT's state when it failed.
- For a specific exception of
com.kms.katalon.core.webui.exception.WebElementNotFoundException: Web element with id ... not found, you can trigger the 'Time Capsule' in either the Log Viewer of a Test Case or a Test Suite Report.
Only applicable to WebUI testing on the Chrome browser.
Turn on/off Time Capsule
This extension works similar to Default Smart Wait . When disabled, the Time Capsule extension will not be installed, and the Time Capsule will not be generated.
Prior to 7.8.2
Time Capsule is enabled by default.
From 7.8.2 onwards
To turn on/ off the Time Capsule, please do as follows:
Go to Project > Settings > Execution > WebUI
In drop-down list of Default Time Capsule, choose Enabled/ Disabled > OK
Failed Test Case Execution scenario
Once a test case execution fails due to
com.kms.katalon.core.webui.exception.WebElementNotFoundException: Web element with id ... not found. In Log Viewer of that test case, you can click on “Click here to fix broken Test Object” to open the captured state of the AUT with the Spy Tool automatically.
Failed Test Suite execution scenario
Similarly, when a Test Suite contains at least one failed Test Case due to broken locators, in Test Suite's Result/Report, you can click on the link “Click here to fix broken Test Object” to open the captured state of the AUT with the Spy Tool automatically.