summaryrefslogtreecommitdiff
path: root/tests/Language/GraphQL/AST/EncoderSpec.hs
diff options
context:
space:
mode:
authorEugen Wissner <belka@caraus.de>2020-09-14 07:49:33 +0200
committerEugen Wissner <belka@caraus.de>2020-09-15 08:06:07 +0200
commit4c10ce92041dc73a95aeb64aca241dd937ffaa5c (patch)
tree6a1742eaf6ff3ae3a4f4d0e2a3c5afbe9a146f4b /tests/Language/GraphQL/AST/EncoderSpec.hs
parent08998dbd935e65aab10ff53c249cb214af2522f2 (diff)
downloadgraphql-4c10ce92041dc73a95aeb64aca241dd937ffaa5c.tar.gz
Use Seq as base monad in the validator
It is more natural to implement the logic: try to apply each rule to each node.
Diffstat (limited to 'tests/Language/GraphQL/AST/EncoderSpec.hs')
-rw-r--r--tests/Language/GraphQL/AST/EncoderSpec.hs8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/Language/GraphQL/AST/EncoderSpec.hs b/tests/Language/GraphQL/AST/EncoderSpec.hs
index 9326fd1..b21e68f 100644
--- a/tests/Language/GraphQL/AST/EncoderSpec.hs
+++ b/tests/Language/GraphQL/AST/EncoderSpec.hs
@@ -121,11 +121,11 @@ spec = do
describe "definition" $
it "indents block strings in arguments" $
- let arguments = [Argument "message" (String "line1\nline2")]
- field = Field Nothing "field" arguments [] [] $ Location 0 0
+ let location = Location 0 0
+ arguments = [Argument "message" (String "line1\nline2") location]
+ field = Field Nothing "field" arguments [] [] location
operation = DefinitionOperation
- $ SelectionSet (pure $ FieldSelection field)
- $ Location 0 0
+ $ SelectionSet (pure $ FieldSelection field) location
in definition pretty operation `shouldBe` [r|{
field(message: """
line1