From 1d6a4b91d7db1cd7d5c66a9a0e5bc4be22e6099b Mon Sep 17 00:00:00 2001 From: Louis Pilfold Date: Fri, 10 Sep 2021 18:59:09 +0100 Subject: JS map decoding --- test/gleam/dynamic_test.gleam | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) (limited to 'test') diff --git a/test/gleam/dynamic_test.gleam b/test/gleam/dynamic_test.gleam index c93210b..b901c86 100644 --- a/test/gleam/dynamic_test.gleam +++ b/test/gleam/dynamic_test.gleam @@ -718,18 +718,16 @@ pub fn typed_tuple6_test() { ))) } -if erlang { - pub fn map_test() { - map.new() - |> dynamic.from - |> dynamic.map - |> should.equal(Ok(map.new())) +pub fn map_test() { + map.new() + |> dynamic.from + |> dynamic.map + |> should.equal(Ok(map.new())) - 1 - |> dynamic.from - |> dynamic.map - |> should.equal(Error(DecodeError(expected: "Map", found: "Int"))) - } + 1 + |> dynamic.from + |> dynamic.map + |> should.equal(Error(DecodeError(expected: "Map", found: "Int"))) } pub fn list_test() { -- cgit v1.2.3