Skip to content

Commit

Permalink
Fix debug test
Browse files Browse the repository at this point in the history
  • Loading branch information
xy2i committed Sep 25, 2022
1 parent d943c93 commit f25c57e
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions tests/integration/date.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,7 @@ use time::{util, Date, Duration, Month, Weekday};

#[test]
fn debug() {
assert_eq!(
format!("{:?}", date!(2020 - 02 - 03)),
"Date { year: 2020, ordinal: 34 }"
);
assert_eq!(format!("{:?}", date!(2020 - 02 - 03)), "2020-02-03");
}

#[test]
Expand Down Expand Up @@ -969,11 +966,9 @@ fn replace_month() {
date!(2022 - 02 - 18).replace_month(Month::January),
Ok(date!(2022 - 01 - 18))
);
assert!(
date!(2022 - 01 - 30)
.replace_month(Month::February)
.is_err()
); // 30 isn't a valid day in February
assert!(date!(2022 - 01 - 30)
.replace_month(Month::February)
.is_err()); // 30 isn't a valid day in February
}

#[test]
Expand Down

0 comments on commit f25c57e

Please sign in to comment.