diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/tests.rs | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/tests.rs b/tests/tests.rs index 7ee0325..9f7f1ca 100644 --- a/tests/tests.rs +++ b/tests/tests.rs @@ -1463,4 +1463,20 @@ fn specific_time() { assert!(false, "didn't match"); } } +} + +#[test] +fn no_space_before_pm() { + let d1 = NaiveDate::from_ymd(1969, 5, 6).and_hms(13, 0, 0); + let d2 = d1 + Duration::hours(1); + match parse("1969-05-06 at 1PM", None) { + Ok((start, end, _)) => { + assert_eq!(d1, start); + assert_eq!(d2, end); + } + Err(e) => { + println!("{:?}", e); + assert!(false, "didn't match"); + } + } }
\ No newline at end of file |