cli: Update examples to use new fail decorator

This commit is contained in:
Alexis Sellier
2023-05-12 12:54:21 +02:00
parent 87ae8cfb62
commit dd7d86abb0
6 changed files with 5 additions and 11 deletions
-6
View File
@@ -8,9 +8,6 @@ use snapbox::cmd::{Command, OutputAssert};
use snapbox::{Assert, Substitutions};
use thiserror::Error;
/// Error lines in the CLI are prefixed with this string.
const ERROR_PREFIX: &str = "✗";
#[derive(Error, Debug)]
pub enum Error {
#[error("parsing failed")]
@@ -160,9 +157,6 @@ impl TestFormula {
},
});
} else if let Some(a) = test.assertions.last_mut() {
if line.starts_with(ERROR_PREFIX) {
a.exit = ExitStatus::Failure;
}
a.expected.push_str(line.as_str());
a.expected.push('\n');
} else {