summaryrefslogtreecommitdiff
path: root/tests/Language
diff options
context:
space:
mode:
authorEugen Wissner <belka@caraus.de>2024-09-17 18:24:41 +0200
committerEugen Wissner <belka@caraus.de>2024-09-17 18:32:45 +0200
commit1834e5c41e8eb7bccd391d54db9453ba2ecfa3b6 (patch)
tree459cc4bc5b6cb2fc260b3b446e453da54fa140f1 /tests/Language
parent01b30a71da8b867269ad78d3091637f197714738 (diff)
downloadgraphql-1834e5c41e8eb7bccd391d54db9453ba2ecfa3b6.tar.gz
Add a test for empty field argument list
... within parens.
Diffstat (limited to 'tests/Language')
-rw-r--r--tests/Language/GraphQL/AST/ParserSpec.hs5
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/Language/GraphQL/AST/ParserSpec.hs b/tests/Language/GraphQL/AST/ParserSpec.hs
index 80c2663..0e7c28a 100644
--- a/tests/Language/GraphQL/AST/ParserSpec.hs
+++ b/tests/Language/GraphQL/AST/ParserSpec.hs
@@ -75,7 +75,10 @@ spec = describe "Parser" $ do
mutation auth{
test(username: """username""", password: """password""")
}|]
-
+
+ it "fails to parse an empty argument list in parens" $
+ parse document "" `shouldFailOn` "{ test() }"
+
it "accepts any arguments" $ mapSize (const 10) $ property $ \xs ->
let
query' :: Text