From df4e6715cf31817878d73286d2d4b1ea1b7afdbb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20F=C3=A4rber?= <01mf02@gmail.com> Date: Fri, 20 Dec 2024 10:48:17 +0100 Subject: HTML tests (#5594) Co-authored-by: Laurenz --- tests/src/logger.rs | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'tests/src/logger.rs') diff --git a/tests/src/logger.rs b/tests/src/logger.rs index 48bad451..18eefa5f 100644 --- a/tests/src/logger.rs +++ b/tests/src/logger.rs @@ -9,8 +9,8 @@ pub struct TestResult { pub errors: String, /// The info log for this test. pub infos: String, - /// Whether the image was mismatched. - pub mismatched_image: bool, + /// Whether the output was mismatched. + pub mismatched_output: bool, } /// Receives status updates by individual test runs. @@ -19,7 +19,7 @@ pub struct Logger<'a> { passed: usize, failed: usize, skipped: usize, - mismatched_image: bool, + mismatched_output: bool, active: Vec<&'a Test>, last_change: Instant, temp_lines: usize, @@ -34,7 +34,7 @@ impl<'a> Logger<'a> { passed: 0, failed: 0, skipped, - mismatched_image: false, + mismatched_output: false, active: vec![], temp_lines: 0, last_change: Instant::now(), @@ -73,7 +73,7 @@ impl<'a> Logger<'a> { self.failed += 1; } - self.mismatched_image |= result.mismatched_image; + self.mismatched_output |= result.mismatched_output; self.last_change = Instant::now(); self.print(move |out| { @@ -102,8 +102,8 @@ impl<'a> Logger<'a> { eprintln!("{passed} passed, {failed} failed, {skipped} skipped"); assert_eq!(selected, passed + failed, "not all tests were executed successfully"); - if self.mismatched_image { - eprintln!(" pass the --update flag to update the reference images"); + if self.mismatched_output { + eprintln!(" pass the --update flag to update the reference output"); } self.failed == 0 -- cgit v1.2.3