Now that you have created some test steps, let's look how these steps are displayed, both in the Keyword View and Editor:
After you have added your steps, the Keyword View should look similar to this:
As you can see, the steps in your test are arranged in an icon-based grid which shows the test step sequence as well as the object hierarchy. Each line in the Keyword View represents a different piece of information:
The HPE MyFlight Sample Applicatio window object is the parent object for the test objects contained in this action.
All test objects contained in the following steps are displayed as sub-nodes to this object.
agentName is the name of the edit box on which UFT performs the action.
The Set method is the action performed on the agentName object.
UFT enters john as the text in the edit box.
password is the name of the edit box on which UFT performs the action.
The SetSecure method is the action performed on the passwordWatermakr object.
UFT enters the digit string as the text in the password edit box.
OK is the name of the button UFT clicks after the information is entered in the agentName and password edit boxes.
The Click method is the action performed on the button.
For each step in the Keyword View, there are a number of different elements:
|Keyword View Element||Description|
|Item||The item for the step (test object, utility object, function call, or statement). This item is displayed in a hierarchical, icon-based tree.|
|Operation||The operation to perform on the Item, such as Click, Set, or Select.|
|Value||The argument values for the selected operation, if required. For example, the text to enter in an edit box, or the mouse button to use when clicking an image.|
|Documentation||The automatically provided statement of what the step does, in an easy-to-understand sentence. For example, Click the "OK" button.|
|Assignment||The assignment of a value to or from a variable so you can use the value later in the test. This column is not visible by default.|
Any textual information you want to add regarding the step. For example, you could ad add a comment Return to page used in first step of test.
This column is not visible by default.
Tip: You can hide or display individual columns by right-clicking the column heading in the Keyword View, and selecting a column name from the list.
After you have added your steps, the Editor should look similar to this:
Unlike the Keyword View, each step in the Editor is represented by a script line, with the format:
<object hierarchy>.<method> <method parameters>
Thus, for each step (and each line in the script), you see a number of things:
|Test object hierarchy||
For each step in the Editor, you get the full object hierarchy, including:
In the first line of the example pictured above, you can see both of these elements:
After the object hierarchy, you also see the method (action to be performed on the object. Each method is displayed as bolded text.
In the first line of the example pictured above, the object performs the Set method.
For many methods, there are required or optional parameters that you must provide. These are listed in the Editor after the method name.
In the first line of the example pictured above, the Set method enters the parameter John.