@@ -198,7 +198,7 @@ utcTimeGood = do
198 assertEqual "utctime" (parseWithRead "%FT%H:%MZ" ts10) t10
198 assertEqual "utctime" (parseWithRead "%FT%H:%MZ" ts10) t10
199 assertEqual "utctime" (parseWithRead "%F %H:%MZ" ts11) t11
199 assertEqual "utctime" (parseWithRead "%F %H:%MZ" ts11) t11
200 assertEqual "utctime" (parseWithRead "%FT%T%QZ" "2015-01-01T14:30:00Z") t12
200 assertEqual "utctime" (parseWithRead "%FT%T%QZ" "2015-01-01T14:30:00Z") t12
202 -- leap seconds are included correctly
202 -- leap seconds are included correctly
203 let ts13 = "2015-08-23T23:59:60.128+00" :: LT.Text
203 let ts13 = "2015-08-23T23:59:60.128+00" :: LT.Text
204 let (Just (t13 :: UTCTime)) = parseWithAeson ts13
204 let (Just (t13 :: UTCTime)) = parseWithAeson ts13
@@ -226,6 +226,7 @@ utcTimeBad = do
226 verifyFailParse "2015-01-01T12:30:00.00+00:00Z" -- no Zulu if offset given
226 verifyFailParse "2015-01-01T12:30:00.00+00:00Z" -- no Zulu if offset given
227 verifyFailParse "2015-01-03 12:13:00.Z" -- decimal at the end but no digits
227 verifyFailParse "2015-01-03 12:13:00.Z" -- decimal at the end but no digits
228 verifyFailParse "2015-01-03 12:13.000Z" -- decimal at the end, but no seconds
228 verifyFailParse "2015-01-03 12:13.000Z" -- decimal at the end, but no seconds
229+ verifyFailParse "2015-01-03 23:59:61Z" -- exceeds allowed seconds per day
230 verifyFailParse (s :: LT.Text) =
231 verifyFailParse (s :: LT.Text) =
231 let (dec :: Maybe UTCTime) = decode . LT.encodeUtf8 $ LT.concat ["\"", s, "\""] in
232 let (dec :: Maybe UTCTime) = decode . LT.encodeUtf8 $ LT.concat ["\"", s, "\""] in