Dropdown Methods
OpenDropdownList
Opens the dropdownList and returns a rectangle for the list (based on rectangle with changes after expanding dropdown list)
Syntax:
Exceptions:
Exception | Condition |
When the dropdown could not be found on the screen. | |
When the dropdown could not be opened after the configured amount of retries. |
SelectImage
Opens the dropdown list, searches the imageReference in the list (incl. scrolling) and selects it. If the image cannot be found, throws a TestStepAbortedException.
The dropdown list is an ItemList<Row> with an IScroller given by the AppBasics.GetScroller passed to the constructor of the dropdown.
Syntax:
Parameters:
Parameter | Description |
imageReference | Type: ImageReference The image reference that shall be selected in the dropdown list. |
Exceptions:
Exception | Condition |
When the dropdown could not be found on the screen. | |
When the dropdown could not be opened after the configured amount of retries. | |
When the image cannot be found in the dropdown list. |
SelectOnScreenElement
Opens the dropdown list, searches for the element in the list (incl. scrolling) and selects it. If the image cannot be found, throws a TestStepAbortedException.
The dropdown list is an ItemList<Row> with an IScroller given by the AppBasics.GetScroller passed to the constructor of the dropdown.
Syntax:
Parameters:
Parameter | Description |
element | Type: OnScreenElement The element that shall be selected in the dropdown list. |
Exceptions:
Exception | Condition |
When the dropdown could not be found on the screen. | |
When the dropdown could not be opened after the configured amount of retries. | |
When the element cannot be found in the dropdown list. |
SelectValue
Opens the dropdown list, searches the text value in the list (incl. scrolling) and selects it. If the text cannot be found, throws a TestStepAbortedException.
The dropdownlist is an ItemList<Row> with an IScroller given by the AppBasics.GetScroller passed to the constructor of the dropdown.
Syntax:
Parameters:
Parameter | Description |
value | Type: String The text that shall be selected in the dropdown list. |
Exceptions:
Exception | Condition |
When the dropdown could not be found on the screen. | |
When the dropdown could not be opened after the configured amount of retries. | |
When the text value cannot be found in the dropdown list. |
VerifySelectedValue
Verifies if the value that is currently set in the TextBox matches the expected value. If it doesn't, the value read from the TextBox is returned as the actualValue out parameter.
Syntax:
Parameters:
Parameter | Description |
value | Type: String The text that shall be verified in the dropdown textbox. |
[actualValue] | Type: String The text that was actually read in the dropdown textbox. |
Return Value:
Whether or not the text value could be found in the dropdown textbox.
Exceptions:
Exception | Condition |
When the dropdown could not be found on the screen. |
VerifyValueInList
Opens the dropdown list and verifies if the provided value is present in the dropdown list (includes scrolling). Closes the dropdown list again.
The dropdown list is an ItemList<Row> with an IScroller given by the AppBasics.GetScroller passed to the constructor of the dropdown.
Syntax:
Parameters:
Parameter | Description |
value | Type: String The text that shall be verified in the dropdown list. |
[takeScreenshot] | Type: Boolean When true, a screenshot of the expanded dropdown is taken, showing the value to verify. |
Return Value:
Whether or not the text value could be found in the dropdown textbox.
Exceptions:
Exception | Condition |
When the dropdown could not be found on the screen. | |
When the dropdown could not be opened after the configured amount of retries. |
Last updated