Forum Discussion
This might be a bit basic, but what about just adding an If..Then statement to look for the needed process to be running.... and if not then launch it.
Hi brumazz , my code looks something like this:
if not (Sys.WaitProcess("myapp.exe").Exists) {
TestedApps.MyApp.Run() // <--- Here Test Complete throws an error 4/10 times, and the execution is stopped even if I put it inside a try/catch
}
The problem here is how TestComplete manages the errors with the "Stop On Error" option selected (or, to be more specific, the fact that TestComplete throws errors on simple actions as opening an application). It would be great if there is a way to ignore these type of errors, because I could simply manage them by "retrying" one more time the same action until succeeds.
- brumazz3 years agoSmartBear Alumni (Retired)
What about changing the playback to retry failed test items?
- TCYKPB3 years agoContributor
brumazz I considered that too, but some of our tests take more than 30 minutes and after that time when an application should be opened to verify something, the "re run" option would add another 30 minutes to the execution just because TC couldn't open an application.
- brumazz3 years agoSmartBear Alumni (Retired)
I'm sorry, I may be confused, but this setting is not going to re-run the entire test....just the failed test step.
So, say you have 1 test step that that validates that the app is open.
Given you have changed that setting, it would retry the validation...not the entire test.
Also, have you tried doing any of this in a KeyWord Test?
Related Content
Recent Discussions
- 21 hours agojstaehlin