Selectors
- tapOn: # or any other command that works with selectors
text: 'Text' # (optional) Finds element with text or accessibility text that matches the regular expression
id: 'the_id' # (optional) Finds element with accessibility identifier that matches the regular expression
index: 0 # (optional) 0-based index of the view to select among those that match all other criteria
point: 50%, 50% # (optional) Relative position on screen. "50%, 50%" is the middle of screen
point: 50, 75 # (optional) Exact coordinates on screen. x:50 y:50, in pixels
width: 100 # (optional) Finds element of a given width
height: 100 # (optional) Finds element of a given height
tolerance: 10 # (optional) Tolerance to apply when comparing width and height
enabled: true # (optional) Searches for view with a given "enabled" state
checked: true # (optional) Searches for view with a given "checked" state
focused: true # (optional) Searches for view with a given "focused" state
selected: true # (optional) Searches for view with a given "selected" stateShorthand selector for text
- tapOn: 'Text' # or any other command that works with selectorsRelative position selectors
Element Traits
Selecting one view among many similar
Using Regular Expressions
Partial Matches
Patterns
Escaping
Should I use text or IDs?
Last updated
Was this helpful?
