Skip to content

Commit

Permalink
introspection-test: fix test to correctly check for exceptions (#2995)
Browse files Browse the repository at this point in the history
  • Loading branch information
IvanGoncharov committed Mar 28, 2021
1 parent 326348e commit 491ddd5
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions src/type/__tests__/introspection-test.js
Expand Up @@ -1577,13 +1577,12 @@ describe('Introspection', () => {
invariant(false, `Called on ${info.parentType.name}::${info.fieldName}`);
}

expect(() =>
graphqlSync({
schema,
source,
fieldResolver,
typeResolver,
}),
).to.not.throw();
const result = graphqlSync({
schema,
source,
fieldResolver,
typeResolver,
});
expect(result).to.not.have.property('errors');
});
});

0 comments on commit 491ddd5

Please sign in to comment.