[][src]Struct augdom::testing::Finder

pub struct Finder<'n, N> { /* fields omitted */ }

Executes a search strategy over a DOM container's subtree via depth-first pre-order traversal.

Implementations

impl<'node, N> Finder<'node, N>[src]

pub fn by_label_text<'find, 'pat>(
    &'find self,
    pattern: &'pat str
) -> Found<'find, 'pat, 'node, N>
[src]

Find by label's or aria-label's normalized text content.

The default choice for selecting form elements as it most closely mirrors how users interact with forms.

pub fn by_placeholder_text<'find, 'pat>(
    &'find self,
    pattern: &'pat str
) -> Found<'find, 'pat, 'node, N>
[src]

Find by input's placeholder value.

Used for form fields, choose if Finder::by_label_text is not available.

pub fn by_role<'find, 'pat>(
    &'find self,
    pattern: &'pat str
) -> Found<'find, 'pat, 'node, N>
[src]

Find by aria role.

The default choice for interactive elements like buttons.

pub fn by_text<'find, 'pat>(
    &'find self,
    pattern: &'pat str
) -> Found<'find, 'pat, 'node, N>
[src]

Find by element's normalized text content.

pub fn by_display_value<'find, 'pat>(
    &'find self,
    pattern: &'pat str
) -> Found<'find, 'pat, 'node, N>
[src]

Find by form element's current value.

pub fn by_alt_text<'find, 'pat>(
    &'find self,
    pattern: &'pat str
) -> Found<'find, 'pat, 'node, N>
[src]

Find by img's alt attribute.

pub fn by_title<'find, 'pat>(
    &'find self,
    pattern: &'pat str
) -> Found<'find, 'pat, 'node, N>
[src]

Find by title attribute's or svg title tag's normalized text content.

pub fn by_test_id<'find, 'pat>(
    &'find self,
    pattern: &'pat str
) -> Found<'find, 'pat, 'node, N>
[src]

Find by data-testid attribute. Not visible to humans, only use as a last resort.

Auto Trait Implementations

impl<'n, N> RefUnwindSafe for Finder<'n, N> where
    N: RefUnwindSafe

impl<'n, N> Send for Finder<'n, N> where
    N: Sync

impl<'n, N> Sync for Finder<'n, N> where
    N: Sync

impl<'n, N> Unpin for Finder<'n, N>

impl<'n, N> UnwindSafe for Finder<'n, N> where
    N: RefUnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.