assertContains
Asserts that the UI element matching string tag contains the substring.
Includes built-in waiting for the text substring to appear.
Example Usage
assertContains("result_summary", "3 items found")Content copied to clipboard
Parameters
tag
The testTag string or visible text of the element.
substring
The expected substring contained within the element's text.
See also
Throws
If the element text does not contain substring within the timeout.
Asserts that the UI element matching selector contains the substring.
Advanced variant using explicit selectors. Includes built-in waiting.
Example Usage
assertContains(tag("description_box"), "Compose Multiplatform")Content copied to clipboard
Parameters
selector
Explicit selector targeting the UI element.
substring
The expected substring contained within the element's text.
Throws
If the element text does not contain substring within the timeout.