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.
Assertion
Hi,
Can you please tell me, what is the significance of "Assertion"? When should we add assert statements? Is it necessary to add assertion in our script?
Thanks in advance!!
Can you please tell me, what is the significance of "Assertion"? When should we add assert statements? Is it necessary to add assertion in our script?
Thanks in advance!!
Comments
If you want to verify that a calculator works correctly, you can
click on 2,
click on +
click on 3
click on =
At this point suppose the result shown by your newly developed awesome calculator is 23.
If you did not assert that the result is 5, your script would report a success!
So you need an assertion when you expect something and want to verify that the actual is the same as the expected value.
Hope that helps.
Regards,
Narayan