Exit actions in UFT
Category:
Question ID: 108942
0
0

Hi. I have a vbs file that drives UFT tests. I have a series of UFT Tests or ‘Actions’. How can I exit/stop UFT from executing more tests, if it fails 1? My understanding is, ExitRun, ExitAction only pertains to a specific action, and if there is another test after it in the pipeline, it will continue to execute. I need both vbscript and UFT to stop executing at that point. Please advise. Thanks.

Marked as spam
Posted by (Questions: 89, Answers: 4)
Asked on April 18, 2019 2:28 pm
337 views
Answers (1)
0
Private answer

You would need to build in some logic to control the execution. First, you would utilize the ExitTest function and return a value back to the main calling test that can handle the run. Next, use the return value and conditional statements to stop the rest of the test.

For example, in your test, you would need the ExitTest statement and the return value. Not knowing the details about the test, I can provide a generic example. Let's say we want the status to be 2 if we want to stop all execution. This can be any value we want:

Marked as spam
Posted by (Questions: 2, Answers: 477)
Answered on April 18, 2019 2:34 pm
EyeOnTesting

Welcome back to "EyeOnTesting" brought to you by Orasi Software, Inc.

X
Scroll to Top