From 0bb11b18f249f5a599e21a00906fd8ccbf21e525 Mon Sep 17 00:00:00 2001 From: Amos Wenger Date: Thu, 1 Aug 2024 21:50:01 +0200 Subject: [PATCH] More coverage --- tests/parsing.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/parsing.rs b/tests/parsing.rs index e0600e410..518661d3b 100644 --- a/tests/parsing.rs +++ b/tests/parsing.rs @@ -457,7 +457,10 @@ fn rfc_3339_err() { OffsetDateTime::parse("2021-01-0", &Rfc3339), invalid_component!("day") )); - // (note: any separator is allowed by RFC 3339) + assert!(matches!( + OffsetDateTime::parse("2021-01-01", &Rfc3339), + invalid_component!("separator") + )); assert!(matches!( OffsetDateTime::parse("2021-01-01T0", &Rfc3339), invalid_component!("hour")