Which is the default ordinal identifier?
By default, an ordinal identifier type exists for each test object class. There three types of Ordinal Identifiers in HP UFT. The value is based on the order in which the object appears within the source code. Index property values are object-specific.
How will you identify an object using XPath in UFT?
Pre-Requisites
- Open UFT and create a new test.
- Disable Smart Identification for the Button test object by selecting Tools > Object Identification.
- Disable automatic XPath by selecting Tools > Options > Web > Advanced, and then making sure that the Learn and run using automatic XPath identifiers checkbox is not selected.
How is descriptive programming used in UFT?
Using Regular Expressions in Descriptive Programming
- Dim oDesc ‘Declare an object variable.
- Set oDesc = Description. Create ‘Create an empty description.
- oDesc(“text”). value= “Go To Next Page user\d\d\d”
- oDesc(“html tag”). value= “A”
- Browser(“QTP Training”). Page(“QTP Training”). Link(oDesc). Click.
What are the four types of parameters in UFT?
148: There are four types of parameters: Test/Action, Random number, Environment Variable, Regular Expression.
Can we use XPath in UFT?
There are two ways of using XPath in UFT. Option 1: Instruct UFT to generate and store XPath value when learning Web test object by doing the setting on “Tools>GUI Testing>Advanced” and select the checkbox as shown below. Option 3: Write the XPath in the object description using Descriptive Programming.
Which of the following is the right syntax to identify a Web edit using XPath?
Selecting Nodes
| Path Expression | Result |
|---|---|
| /bookstore | Selects the root element bookstore Note: If the path starts with a slash ( / ) it always represents an absolute path to an element! |
| bookstore/book | Selects all book elements that are children of bookstore |
| //book | Selects all book elements no matter where they are in the document |
Which of these is a descriptive programming?
Descriptive Programming is a mechanism for creating tests where you use “Programmatic description” of objects instead of recording them. Using this technique, QTP can be made to identify objects that are not in the repository. There are 2 variations of Descriptive Programming: Static Descriptive programming.