There is a good QTP recovery scenario called "Any error":
But still QTP is not firing recovery scenario in several cases (as I've found here):
- Script Errors
- Object Not in Object Repository (OR)
- Modal dialog blocking execution
- Associated Library is not found
- Activate Recovery Scenario setting is not configured properly
If you are going to execute a set of tests automatically (VB script that executes one test after another), as soon as you come to an error which can not be seen (and also handled) by QTP recovery scenario all the test will not be executed from this time, testing process would stuck at this point.
Is there any way to avoid this problem (need automation solution!), how to reset QTP test execution without recovery scenario (to close/kill qtp process, open next test in qtp)?
Till now: I see solution as setting timeout for test execution (e.g. Test1 - 1:30) if timeout is expired and test is not completed the test should be closed. But there is no good-looking timeout realization as I see in VBScript.