Improve behavior and reporting of tests expected to fail

Fixes #786.
This commit is contained in:
KtorZ
2024-01-19 18:18:44 +01:00
parent 94f9fa9cab
commit 8a90e9eda0
8 changed files with 96 additions and 14 deletions

View File

@@ -35,6 +35,7 @@ impl EvalResult {
pub fn failed(&self, can_error: bool) -> bool {
if can_error {
self.result.is_ok()
&& !matches!(self.result, Ok(Term::Constant(ref con)) if matches!(con.as_ref(), Constant::Bool(false)))
} else {
self.result.is_err()
|| matches!(self.result, Ok(Term::Error))