diff --git a/core/src/date/day.rs b/core/src/date/day.rs index 05ca27b8..1ea281f9 100644 --- a/core/src/date/day.rs +++ b/core/src/date/day.rs @@ -48,13 +48,13 @@ mod tests { use super::*; #[test] - #[should_panic] + #[should_panic(expected = "day value 0 is out of range")] fn day_0() { Day::new(0); } #[test] - #[should_panic] + #[should_panic(expected = "day value 32 is out of range")] fn day_32() { Day::new(32); } diff --git a/core/src/date/year.rs b/core/src/date/year.rs index 94278e09..b1e871ec 100644 --- a/core/src/date/year.rs +++ b/core/src/date/year.rs @@ -101,7 +101,7 @@ mod tests { use super::*; #[test] - #[should_panic] + #[should_panic(expected = "year 0 is invalid")] fn year_0() { Year::new(0); }