Forum Discussion
AlexKaras
4 years agoChampion Level 3
Hi Pankhuri,
Sample code that utilizes script global or Project variable:
function OnStartTestCase ()
{
Project.Variables.InOnStopTestCaseHandler = false;
}
function OnStopTestCase()
{
if (Project.Variables.InOnStopTestCaseHandler)
exit;
Project.Variables.InOnStopTestCaseHandler = true;
...
// do whatever you need here
...
Project.Variables.InOnStopTestCaseHandler = false;
}
- pankhuri4 years agoOccasional Contributor
Hi Alex,
Thank you for providing a sample code. The logic makes sense, however when i was using Exit procedure, it is not working. It is giving error as not defined in python. Does it not work with python language?
Also, how to call this exit, i am just using Exit() to call this procedure. Let me know if this is not the right way.
Thanks,
Pankhuri
Related Content
- 3 years ago
- 5 years ago