diff --git a/tests/PhotoGrooveTest.elm b/tests/PhotoGrooveTest.elm index 0a3a767..e93ae28 100644 --- a/tests/PhotoGrooveTest.elm +++ b/tests/PhotoGrooveTest.elm @@ -13,14 +13,11 @@ suite = describe "photoDecoder" [ fuzz2 Fuzz.string Fuzz.int "title always defaults to '(untitled)'" <| \url size -> - mkPhoto url size + [ ( "url", Encode.string url ) + , ( "size", Encode.int size ) + ] + |> Encode.object |> J.decodeValue Testee.photoDecoder |> Result.map .title |> Expect.equal (Ok "(untitled)") ] - - -mkPhoto : String -> Int -> Value -mkPhoto url size = - [ ( "url", Encode.string url ), ( "size", Encode.int size ) ] - |> Encode.object