Skip to content

Commit

Permalink
fix: Remove deprecated set_soundness from time 0.3.37
Browse files Browse the repository at this point in the history
It is not longer needed.

More info: https://github.com/time-rs/time/blob/main/CHANGELOG.md#0337-2024-12-03

Signed-off-by: Alexander Gil <[email protected]>
  • Loading branch information
pando85 committed Dec 3, 2024
1 parent 797042a commit 286149d
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions src/timer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -177,11 +177,6 @@ mod tests {
#[cfg(not(target_os = "macos"))]
#[test]
fn test_parse_end_time() {
// Workaround `OffsetDateTime::now_local()` failing in tests:
// https://github.com/time-rs/time/blob/main/CHANGELOG.md#0318-2023-02-16
unsafe {
time::util::local_offset::set_soundness(time::util::local_offset::Soundness::Unsound);
}
let now = OffsetDateTime::now_local().ok().unwrap();

let date = parse_end_time("12:00").unwrap();
Expand All @@ -194,11 +189,6 @@ mod tests {
#[cfg(not(target_os = "macos"))]
#[test]
fn test_parse_end_time_leading_zero() {
// Workaround `OffsetDateTime::now_local()` failing in tests:
// https://github.com/time-rs/time/blob/main/CHANGELOG.md#0318-2023-02-16
unsafe {
time::util::local_offset::set_soundness(time::util::local_offset::Soundness::Unsound);
}
let now = OffsetDateTime::now_local().ok().unwrap();

let date = parse_end_time("9:30").unwrap();
Expand Down

0 comments on commit 286149d

Please sign in to comment.