Function When_I_find_element_by_role

  • When I find element by role:

    When I find element by role {string}
    

    Queries for the first element with the given role.

    Parameters

    • role: string
    • Optionaloptions: DataTable

    Returns void

    When I find element by role "progressbar"
    

    With options:

    When I find element by role "progressbar"
    | log | true |
    | timeout | 4000 |
    | withinSubject | null |
    | includeShadowDom | false |

    This precedes steps like "When I click". For example:

    When I find element by role "progressbar"
    And I click

    Inspired by Testing Library's ByRole.