Skip to content

Commit

Permalink
Add overflow test cases
Browse files Browse the repository at this point in the history
  • Loading branch information
adpaco-aws committed Nov 22, 2024
1 parent b01dff6 commit 23c68ea
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion cedar-lean/UnitTest/Datetime.lean
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,10 @@ def testsForInvalidDurationStrings :=
testInvalid "1s1d" "invalid order",
testInvalid "1s1s" "repeated units",
testInvalid "1d2h3m4s5ms " "trailing space",
testInvalid " 1d2h3m4s5ms" "leading space"
testInvalid " 1d2h3m4s5ms" "leading space",
testInvalid "1d9223372036854775807ms" "overflow",
testInvalid "1d92233720368547758071ms" "overflow ms",
testInvalid "9223372036854776s1ms" "overflow s"
]

def tests := [testsForValidDurationStrings, testsForInvalidDurationStrings]
Expand Down

0 comments on commit 23c68ea

Please sign in to comment.