I am testing a webservice and need to disable a few checkpoints at runtime. Those checkpoints won't be mandatory for certain arrays, and the test would fail with them. Is there any possibility of using custom code, or an existing UFT feature, to do this?
-
Can you add a test case that looks for a variable that tells it to run the checkpoint or not? – dmcgill50 Mar 01 '17 at 15:48
-
I dont think this will work with my flow.. anyways thanks for your suggestion – Ricky Mar 07 '17 at 05:00
4 Answers
After some analysis, I see two ways of handling checkpoints during run time.
1. Include the checkpoint(s) in your script using If,Else flow controls and not using Properties tab. This will give greater control over enabling/disabling checkpoints and will help make reporting easier as well. This approach involves extra work as compared to doing it from Properties tab.
2. Include the checkpoints using "CodecheckPointEvent
" event. This involves extensive coding and the the "XPath
" of array elements might be tricky/too long to use. This approach needs some C# coding knowledge.
Hope this helps.

- 3,759
- 3
- 22
- 50

- 31
- 3
-
Yep.. thats true .. Iwas aware of that C# thing coming up.. However thanks for the first point. I will try that. thanks for your help – Ricky Mar 07 '17 at 04:58
I too am searching for ways to do this. "CodeCheckPointEvent" has just three options, one property and two methods, to work on the checkpoint and none of them help to control the checkpoint(s) set using the properties tab.

- 31
- 3
I don't think we have any way to stop checkpoints from executing in UFT API tests. But if this is the requirement then you can always take the another approach
Create an event after test and in that event parse and validate the response. If the validation fails then report it in the results.

- 188
- 8
I had no choice but to write custom code in C# to complete teh task.
Thanks for your help mates..

- 73
- 1
- 12