18 January 2026:
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
Stop on Javascript errors
Hello.
Is there any way I can configure Sahi to stop on Javascript errors in tests? Currently I got one test that is shown as completed, but is has a warning inside about JS errors, but I need to fail and stop test on it.
Is there any way I can configure Sahi to stop on Javascript errors in tests? Currently I got one test that is shown as completed, but is has a warning inside about JS errors, but I need to fail and stop test on it.
Comments
its stopping on JS errors...
if not, please correct me and provide an example
You could wrap your script in a try-catch block and then use the _logExeptionAsFailure() API.. this should stop execution.
Regards
Wormi
I'm also waiting for answer on this question as test case failing when i run manually due js error, but the same is passing when i run through sahi pro script. please provide where i have to update regarding to fail the automation test case for js errors. Earliest response will be great for this as i'm blocking on this scenario.