graphql
graphql copied to clipboard
How to use addMocksToSchema with neo4jGraphQL schema ?
I use addMocksToSchema to test schema and validate queries and resolvers.
When I try to use the same after migration from neo4j-graphql-js, it gives an error
Unknown directive "@exclude".
Unknown directive "@relationship".
Let me know if there is a better option to test schema.
let schema=neo4jGraphQL.getSchema().then(async function(schema) { await addMocksToSchema({ schema: schema, mocks }); return schema });
Thanks