pub enum PatternError {
Placeholder(PlaceholderErrorInfo),
Regex(Error),
}
Expand description
Errors surfaced while converting step patterns into regular expressions.
§Examples
use rstest_bdd_patterns::{PatternError, PlaceholderErrorInfo};
let info = PlaceholderErrorInfo::new("invalid", 2, Some("count".into()));
let err = PatternError::Placeholder(info.clone());
assert_eq!(err.to_string(), info.to_string());
Variants§
Placeholder(PlaceholderErrorInfo)
Regex(Error)
Trait Implementations§
Source§impl Debug for PatternError
impl Debug for PatternError
Source§impl Display for PatternError
impl Display for PatternError
Source§impl Error for PatternError
impl Error for PatternError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for PatternError
impl RefUnwindSafe for PatternError
impl Send for PatternError
impl Sync for PatternError
impl Unpin for PatternError
impl UnwindSafe for PatternError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more