summaryrefslogtreecommitdiff
path: root/tests/Test
AgeCommit message (Collapse)Author
2019-12-06Support directives (skip and include)Eugen Wissner
Fixes #24.
2019-12-02Consider __typename when evaluating fragmentsEugen Wissner
Fixes #30.
2019-11-14Fail on cyclic fragments, fix #22Eugen Wissner
2019-11-12Support nested fragments in any orderEugen Wissner
Fix #19.
2019-11-09Support nested fragmentsEugen Wissner
... without forward lookup.
2019-11-03Move related modules to Language.GraphQL.ASTEugen Wissner
Fixes #18. - `Language.GraphQL.Encoder` moved to `Language.GraphQL.AST.Encoder`. - `Language.GraphQL.Parser` moved to `Language.GraphQL.AST.Parser`. - `Language.GraphQL.Lexer` moved to `Language.GraphQL.AST.Lexer`. - All `Language.GraphQL.AST.Value` data constructor prefixes were removed. The module should be imported qualified. - All `Language.GraphQL.AST.Core.Value` data constructor prefixes were removed. The module should be imported qualified. - `Language.GraphQL.AST.Transform` is now isn't exposed publically anymore.
2019-10-19Handle top-level fragmentsEugen Wissner
Fixes #17.
2019-10-11Inline fragments without typeEugen Wissner
Fixes #11.
2019-10-08Support inline fragments on typesEugen Wissner
2019-09-27Introduce hspec-megaparsecEugen Wissner
Fixes #13.
2019-09-13Add pending inline fragment testsEugen Wissner
2019-09-01Deprecate enum, enumA, wrappedEnum, wrappedEnumAEugen Wissner
These functions are from Language.GraphQL.Schema. There are actually only two generic types in GraphQL: Scalars and objects. Enum is a scalar value. According to the specification enums may be serailized to strings. And in the current implementation they used untyped strings anyway, so there is no point to have differently named functions with the same implementation as their scalar counterparts.
2019-08-30Deprecate Language.GraphQL.Execute.SchemaEugen Wissner
It is not a schema (at least not a complete one), but a resolver list, and the resolvers should be provided by the user separately, because the schema can originate from a GraphQL document. Schema name should be free to provide a data type for the real schema later.
2019-08-05Make all encoder functions return lazy textEugen Wissner
2019-08-03Implement indentation in the encoderEugen Wissner
2019-08-02Put spaces between tokens in the pretty printerEugen Wissner
2019-07-31Introduce formatter type for the encoderEugen Wissner
... to distinguish between minified and pretty printing.
2019-07-27Test the encoder with the unminified documentEugen Wissner
2019-07-14Make all exports explicitEugen Wissner
2019-07-10Replace tasty and HUnit with HspecEugen Wissner
2019-07-08Constrain the resolvers with MonadIOEugen Wissner
This replaces the most usages of MonadPlus, which is not appropriate for the resolvers, since a resolver is unambiguously chosen by the name (no need for 'mplus'), and the resolvers are often doing IO.
2019-07-07Change the main namespace to Language.GraphQLEugen Wissner
2019-07-05Allow resolvers to return arbitrary nested listsEugen Wissner
2019-07-03Add nullable typesEugen Wissner
2019-07-02Introduce monad transformer for resolversEugen Wissner
Now the errors in the resolvers can be handled and 3 tests throwing errors pass now. Another test fail but it requires distinguisching nullable and non-nullable values.
2019-06-28Replace Alternative with MonadPlusEugen Wissner
2019-06-27Restore error handlingEugen Wissner
2017-03-03When argument is not found return nullDanny Navarro
The relevant test was restored too.
2017-03-01Implement type instrospection testsDanny Navarro
The main intention with this commit is to show a poor's man way to support type instrospection.
2017-02-23Add basic Fragment SupportDanny Navarro
Only field names are supported for now.
2017-01-30Define Schema using Core ASTDanny Navarro
Also, temporarily remove error reporting to simplify execution. This should be restored once the new execution model is nailed.
2017-01-28Split AST in 2Danny Navarro
One AST is meant to be a target parser and tries to adhere as much as possible to the spec. The other is a simplified version of that AST meant for execution. Also newtypes have been replaced by type synonyms and NonEmpty lists are being used where it makes sense.
2016-12-18Add homePlanet to test schemaDanny Navarro
2016-07-08add tests for errors in queries for queries in starwars testsPweaver (Paul Weaver)
2016-07-08adds __typename tests to starwars testfilePweaver (Paul Weaver)
2016-07-08adds the starwars tests for fragmentsPweaver (Paul Weaver)
Also refactors some deplicate objects into a where clause
2016-03-14Added exception handling with Alternative constraint according to spec.Matthías Páll Gissurarson
2016-02-22Remove `StringValue` typeDanny Navarro
2016-02-19Simplify Schema definition APIDanny Navarro
Now there is one `Resolver` type and the `Output` and `Scalar` types have been removed. This should be closer to the final Schema definition API.
2016-02-18Overhaul Schema DSLDanny Navarro
Aside of making the definition of Schemas easier, it takes care of issues like nested aliases which previously wasn't possible. The naming of the DSL functions is still provisional.
2016-02-17Initial support for aliases in `execute`Danny Navarro
2016-02-17Add remaining tests with variables in argumentsDanny Navarro
The test with invalid ID is commented out until proper exception handling is implemented.
2016-02-15Initial support for variable substitutionDanny Navarro
The correspondent end-to-end test has been ported. The variable definition still needs to be checked.
2016-02-15Clean up StarWars test queriesDanny Navarro
2016-02-12Split StarWars tests in different modulesDanny Navarro
2016-02-12Handle Field arguments in Schema definitionDanny Navarro
The `Schema` has been overhauled to make `Output` monomorphic. Traversing the `GraphQL` document is handled implicitly while defining the `Schema`. The 4th end-to-end test from `graphql-js` has been ported.
2016-02-09Split Character data type into Droid and HumanDanny Navarro
`Character` is now a synonym of the sum type of `Droid` and `Human`. For now I don't see the need to implement GraphQL Schema interfaces with type classes or lens. Plain Haskell ADTs should be good enough.
2016-02-09Handle Output enumerations in Schema definitionDanny Navarro
The third end-to-end test from graphql-js was implemented.
2016-02-08Extend `execute` for deeper queriesDanny Navarro
The second graphql-js end-to-end test was ported and passed successfully.
2016-02-05Simplify JSON notation in testsDanny Navarro