Enum bpaf::ParseFailure
source · Expand description
Unsuccessful command line parsing outcome, use it for unit tests
Useful for unit testing for user parsers, consume it with
ParseFailure::unwrap_stdout
and ParseFailure::unwrap_stdout
Variants§
Stdout(String)
Print this to stdout and exit with success code
Stderr(String)
Print this to stderr and exit with failure code
Implementations§
source§impl ParseFailure
impl ParseFailure
sourcepub fn unwrap_stderr(self) -> String
pub fn unwrap_stderr(self) -> String
sourcepub fn unwrap_stdout(self) -> String
pub fn unwrap_stdout(self) -> String
Trait Implementations§
source§impl Clone for ParseFailure
impl Clone for ParseFailure
source§fn clone(&self) -> ParseFailure
fn clone(&self) -> ParseFailure
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read more