diff options
Diffstat (limited to 'test/gleam_json_test.gleam')
-rw-r--r-- | test/gleam_json_test.gleam | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/test/gleam_json_test.gleam b/test/gleam_json_test.gleam index 69c5550..f27edce 100644 --- a/test/gleam_json_test.gleam +++ b/test/gleam_json_test.gleam @@ -130,14 +130,12 @@ fn should_encode(data: Json, expected: String) { |> should.equal(json.to_string(data)) } -if erlang { - fn empty_list_decode_error() -> dynamic.DecodeError { - dynamic.DecodeError(expected: "Int", found: "List", path: []) - } +@target(erlang) +fn empty_list_decode_error() -> dynamic.DecodeError { + dynamic.DecodeError(expected: "Int", found: "List", path: []) } -if javascript { - fn empty_list_decode_error() { - dynamic.DecodeError(expected: "Int", found: "Tuple of 0 elements", path: []) - } +@target(javascript) +fn empty_list_decode_error() { + dynamic.DecodeError(expected: "Int", found: "Tuple of 0 elements", path: []) } |