Best practice for error handling in Rapise

Tuesday, October 16, 2012
Avatar
What is the best way of taking care of error handling in Rapise? Are there any general examples?
2 Replies
Wednesday, October 17, 2012
Avatar
re: jennyda Tuesday, October 16, 2012

Hi Jenny

In general you just use the Javascript try { .... } catch (ex) structures.

http://www.w3schools.com/js/js_try_catch.asp

Regards

Adam

3 hours 2 minutes ago
Avatar
re: jennyda Tuesday, October 16, 2012

In Rapise, the most effective way to handle errors is to combine structured checks with proper logging and recovery logic rather than relying only on global error catching.

A common approach is:

  • Use Tester.Assert() or Verifier statements to validate expected states
  • Wrap risky steps in try…catch blocks so the script doesn’t stop completely on failure
  • Add conditional checks (e.g., element exists/visible) before interacting with objects
  • Log meaningful messages using Tester.Message() to help with debugging
  • For reusable flows, create helper functions that include built-in error handling

A simple pattern many teams use is: try action → verify result → log failure → optionally continue or stop based on severity.

Also, when sharing test run recordings or demos of error handling flows, tools like capcut no watermark are often used to clean up videos so the focus stays on the actual test behavior

Spira Helps You Deliver Quality Software, Faster and With Lower Risk

And if you have any questions, please email or call us at +1 (202) 558-6885

 

Statistics
  • Started: Tuesday, October 16, 2012
  • Last Reply: 3 hours 2 minutes ago
  • Replies: 2
  • Views: 21720