Fix broken intra-doc links
This commit is contained in:
parent
fbe60feb7e
commit
885d45f435
7 changed files with 21 additions and 21 deletions
|
|
@ -4,7 +4,7 @@ use std::sync::Arc;
|
|||
/// A test error.
|
||||
#[derive(Debug, Clone, thiserror::Error)]
|
||||
pub enum Error {
|
||||
/// No matching widget was found for the [`Selector`].
|
||||
/// No matching widget was found for the [`Selector`](crate::Selector).
|
||||
#[error("no matching widget was found for the selector: {selector}")]
|
||||
NotFound { selector: String },
|
||||
#[error("the matching target is not visible: {target:?}")]
|
||||
|
|
|
|||
|
|
@ -34,8 +34,8 @@
|
|||
//! let _ = ui.click("-");
|
||||
//! ```
|
||||
//!
|
||||
//! [`Simulator::click`] takes a [`Selector`]. A [`Selector`] describes a way to query the widgets of an interface. In this case,
|
||||
//! [`selector::text`] lets us select a widget by the text it contains.
|
||||
//! [`Simulator::click`] takes a type implementing the [`Selector`] trait. A [`Selector`] describes a way to query the widgets of an interface.
|
||||
//! In this case, we leverage the [`Selector`] implementation of `&str`, which selects a widget by the text it contains.
|
||||
//!
|
||||
//! We can now process any messages produced by these interactions and then assert that the final value of our counter is
|
||||
//! indeed `1`!
|
||||
|
|
|
|||
|
|
@ -100,7 +100,7 @@ where
|
|||
}
|
||||
}
|
||||
|
||||
/// Finds the [`Target`] of the given widget [`Selector`] in the [`Simulator`].
|
||||
/// Finds the target of the given widget [`Selector`] in the [`Simulator`].
|
||||
pub fn find<S>(&mut self, selector: S) -> Result<S::Output, Error>
|
||||
where
|
||||
S: Selector + Send,
|
||||
|
|
@ -135,10 +135,10 @@ where
|
|||
self.cursor = mouse::Cursor::Available(position.into());
|
||||
}
|
||||
|
||||
/// Clicks the [`Target`] found by the given [`Selector`], if any.
|
||||
/// Clicks the [`Bounded`] target found by the given [`Selector`], if any.
|
||||
///
|
||||
/// This consists in:
|
||||
/// - Pointing the mouse cursor at the center of the [`Target`].
|
||||
/// - Pointing the mouse cursor at the center of the [`Bounded`] target.
|
||||
/// - Simulating a [`click`].
|
||||
pub fn click<S>(&mut self, selector: S) -> Result<S::Output, Error>
|
||||
where
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue