diff options
author | Louis Pilfold <louis@lpil.uk> | 2023-04-10 10:28:56 +0100 |
---|---|---|
committer | Louis Pilfold <louis@lpil.uk> | 2023-04-10 10:51:24 +0100 |
commit | 52d992c7e82a87b6a6d430ce565fad14ed7952c6 (patch) | |
tree | a0bb28080358bc46569f01e18e59a1a9b656beff /test | |
parent | c7a77c9c0ce1731e4c849556777465d0b789a955 (diff) | |
download | gleam_stdlib-52d992c7e82a87b6a6d430ce565fad14ed7952c6.tar.gz gleam_stdlib-52d992c7e82a87b6a6d430ce565fad14ed7952c6.zip |
PMap property test
Diffstat (limited to 'test')
-rw-r--r-- | test/gleam/map_test.gleam | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/gleam/map_test.gleam b/test/gleam/map_test.gleam index 5cfb37d..75fb78d 100644 --- a/test/gleam/map_test.gleam +++ b/test/gleam/map_test.gleam @@ -361,3 +361,17 @@ pub fn peters_bug_test() { |> map.get(0) |> should.equal(Error(Nil)) } + +pub fn zero_must_be_contained_test() { + let map = + map.new() + |> map.insert(0, Nil) + + map + |> map.get(0) + |> should.equal(Ok(Nil)) + + map + |> map.has_key(0) + |> should.equal(True) +} |