Skip to content

Commit bd726d1

Browse files
committed
add tests
1 parent f73f870 commit bd726d1

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/config.test.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,13 @@ describe('validateConfig', () => {
1919
'`options.skipTypename` must be a boolean',
2020
);
2121
});
22+
it('skipIsAbstractType', () => {
23+
expect(() => validateConfig({ typesFile: './types', skipIsAbstractType: oneOf([true, false]) })).not.toThrow();
24+
expect(() => validateConfig({ typesFile: './types' })).not.toThrow();
25+
expect(() => validateConfig({ typesFile: './types', skipIsAbstractType: 1 })).toThrow(
26+
'`options.skipIsAbstractType` must be a boolean',
27+
);
28+
});
2229
it('typesPrefix', () => {
2330
expect(() => validateConfig({ typesFile: './types', typesPrefix: 'Prefix' })).not.toThrow();
2431
expect(() => validateConfig({ typesFile: './types' })).not.toThrow();

0 commit comments

Comments
 (0)