11-12-2013 01:25 AM - edited 11-12-2013 01:31 AM
im using HP UFT 11.5 and HP ALM. I need to construct one big test of a java application with the following critical condition:
In some points in the test i need to choose different elements from a list. For example i want the test to pick Element X from the list, whereas in another testrun i want the test to pick Element Y. My question is how can i
1) create such a test in HP UFT
2) control before a testrun which Element to pick
Thank you in advance
11-13-2013 03:38 AM
The proper way is to use a data table. The data table would contain one or more fields where you can enter the element that you want to use for each iteration of the test. When you run the test, it will iterate through the data table, one row at a time, and enter the parameter value into where ever you need it in the test.
11-13-2013 04:09 AM
Totally Right, using UFT Datatable you can save each value you want to select for the iteration this is the best way
Also if you don't want to use datatable and what you want is just type your selection manually during runtime you can use inputtext before execute the lines to choose the element.
myvariable = inputbox ("type the element you want to select")