Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions src/type/__tests__/definition-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -1180,3 +1180,20 @@ describe('Type System: NonNull must only accept non-nullable types', () => {
});
}
});

describe('Type System: Configs', () => {
it('GraphQLObjectType have correct configs', () => {
const objectConfig = {
name: 'Object',
fields: {},
description: 'Graphql object type',
isTypeOf: () => true,
interfaces: [],
astNode: null,
extensionASTNodes: [],
};
const someObjectType = new GraphQLObjectType(objectConfig);

expect(someObjectType.toConfig()).to.deep.equal(objectConfig);
});
});