Skip to content

Commit

Permalink
Delete a redundant test
Browse files Browse the repository at this point in the history
  • Loading branch information
emabee committed Jun 21, 2024
1 parent a306c2b commit f93e392
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 19 deletions.
4 changes: 2 additions & 2 deletions tests/test_force_utc_1_panic.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use flexi_logger::{DeferredNow, Logger};
use log::*;

#[test]
#[should_panic]
#[should_panic(expected = "offset is already initialized not to enforce UTC")]
fn test_force_utc_1_panic() {
let _ = Logger::try_with_str("info")
.unwrap()
Expand All @@ -13,5 +13,5 @@ fn test_force_utc_1_panic() {
.unwrap_or_else(|e| panic!("Logger initialization failed with {e}"));
info!("MUST BE REACHED");
DeferredNow::force_utc();
info!("MUST NOT BE REACHED");
assert!(false, "MUST NOT BE REACHED");
}
17 changes: 0 additions & 17 deletions tests/test_force_utc_2_panic.rs

This file was deleted.

2 changes: 2 additions & 0 deletions tests/test_force_utc_3.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ use flexi_logger::{DeferredNow, Logger};
use log::*;

#[test]
#[should_panic(expected = "we arrived here, everything OK")]
fn test_force_utc_3() {
DeferredNow::force_utc();
let _ = Logger::try_with_str("info")
Expand All @@ -12,4 +13,5 @@ fn test_force_utc_3() {
.unwrap_or_else(|e| panic!("Logger initialization failed with {e}"));
DeferredNow::force_utc();
info!("must be printed");
assert!(false, "we arrived here, everything OK");
}

0 comments on commit f93e392

Please sign in to comment.