55.8 Placeholders
55.8.1 Placeholders for node attributes (apart from component nodes)
The following table describes the placeholders that can be used to query information
about a recorded step that does not relate to the component itself.
Such placeholders can be used enclosed in angle brackets (e.g. <text>)
as the value of an attribute in the
attributes section, as the value
of a parameter in set procedure call parameters, as the value
of a doctag in doctags, or in an
expression in the condition section.
The name of placeholders for attributes and component nodes corresponds to the name of
the associated YAML attribute in the
attributes section. Spaces used in
YAML names are omitted in the placeholders.
| Placeholder | Description |
|---|---|
| client |
The client under which the event was recorded (content of the step attribute
client, usually a variable such as $(client)).
|
| client name | The full (absolute) name of the client on which the event was recorded. |
| check type |
The Check type identifier of the step, e.g. for Boolean check nodes one of the
values selected, checked,
visible, or enabled. Also available as alias
checktype.
|
| <componentid> |
The value of the placeholder has to match exactly the QF-Test component ID of the node to be converted.
In a Procedure call definition the respective key is in the section
attributes.
|
| detail |
Additional, event-specific detail information, e.g. the specifications for a
recorded swipe gesture (see startx, starty,
endx, endy, and swipeduration below).
|
| file | The file name or path of the recorded event. |
| height | The height of the window or component. |
| width | The width of the window or component. |
| keychar | The character of a recorded keyboard event. |
| keycode | The key code of a recorded keyboard event. |
| modifiers | The modifier keys pressed during the event (e.g. Shift, Ctrl), encoded as a numeric value. |
| clicks | The number of mouse clicks of the recorded Mouse event. |
| hardclick | Whether the recorded Mouse event was a "hard" mouse click that bypasses normal focus handling. |
| popup | Whether the recorded mouse click triggered a context menu (popup). |
| x | The x-coordinate of the event; for Component event nodes the first parameter of the step. |
| y | The y-coordinate of the event; for Component event nodes the second parameter of the step. |
| startx, starty, endx, endy, swipeduration |
Start and end coordinates and duration of a recorded swipe gesture. These
placeholders only return a value if the value in the detail
attribute of the node to be converted starts with swipe: .
|
| procedure | Procedure name of a Procedure call's. |
| window | The name of the window in which the event occurred. |
| singleevents | Whether the text input in a Text input was performed via individual key events. |
| clear | Whether the existing text in a Text input was cleared before input. |
| text, VALUE |
The recorded text or current value of the component at the time of the event.
For Text input and Check text nodes: the entered or expected text.
For other events on sub-elements, e.g. of tables or lists: the recorded value
of the affected sub-element; otherwise the current selection state of the
component. Also available as aliases currentvalue and
value.
|
| selectedstate, checkedstate, visiblestate, enabledstate, editablestate, state |
The state of the component recorded at the time of the event. For
Boolean check nodes the states are instead derived from the expected
state (
For checkboxes, radio buttons, toggle buttons, and menu items clicked with
a mouse click, |
| items |
The list of entries of a Check items node.
By default, list entries are separated by |||. You can set a
different value via the option "OPT_RECORDING_PROCESSOR_ITEMLIST_SEPARATOR"
in a server script.
|
| itemswithselection |
The list of entries of a Check selectable items node together with their
selection state, separated as for the items placeholder.
|
| event |
The name of the event, e.g. MOUSE_CLICK for the
Event attribute of a Mouse event, or
KEY_STROKE for a Key event.
|
| resultvariable | The name of the variable into which the index is written for Fetch index nodes. |
| variable name |
The name of the variable that receives the return value of a Procedure call
(Variable for return value). Also available as aliases
returnvariable and variablename.
|
| localvariable | Whether the result variable, e.g. of a Check node, is a local variable. |
55.8.2 Placeholders for component nodes
| Placeholder | Description |
|---|---|
| <id> | The QF-Test ID of a Component node. |
| <name> | The name of the component. |
| <feature> | The feature of the component. |
| <class> | The recorded class of the component. |
| <COMPEF-name-of-extra-feature> | The value of the specified extra feature of the component. |
| <ENGINE> | The name of the engine, either 'awt', 'swt', 'web', or 'fx'. |
| <ENGINE2> | The alternative name of the engine, either 'swing', 'swt', 'web', or 'fx'. |
55.8.3 Placeholders for component states in the SUT
The state placeholders selectedstate,
checkedstate, visiblestate,
enabledstate, and editablestate are only available as
placeholders and are not YAML attributes in their own right.
| Placeholder | Description |
|---|---|
| <enabledstate> | The state at the time of recording, indicating whether the component is enabled. |
| <selectedstate> | The state at the time of recording, indicating whether the component is selected. For mouse clicks on checkboxes, radio buttons, toggle buttons, and selectable menu items: the (old) state before the click. |
| <checkedstate> | For mouse clicks on checkboxes, radio buttons, toggle buttons, and selectable menu items: the expected (new) state resulting from the click, indicating whether the component is checked or activated. Technically this is the negated value of the state before the click. For other node types, the "checked" or "activated" state of the component is returned. |
| <editablestate> | The state at the time of recording, indicating whether the component is editable. |
| <visiblestate> | The state at the time of recording, indicating whether the component is visible. |