diff --git a/tests/iso-date/Date.test.ts b/tests/iso-date/Date.test.ts index 687002f11..cc778d777 100644 --- a/tests/iso-date/Date.test.ts +++ b/tests/iso-date/Date.test.ts @@ -87,6 +87,7 @@ describe('GraphQLDate', () => { }; it(`parses literal ${stringify(literal)} into javascript Date ${stringify(expected)}`, () => { + // @ts-expect-error - intentional invalid input expect(GraphQLDate.parseLiteral(literal, {})).toEqual(expected); }); }); @@ -97,6 +98,7 @@ describe('GraphQLDate', () => { value, }; it(`errors when parsing invalid literal ${stringify(invalidLiteral)}`, () => { + // @ts-expect-error - intentional invalid input expect(() => GraphQLDate.parseLiteral(invalidLiteral, {})).toThrowErrorMatchingSnapshot(); }); }); diff --git a/tests/iso-date/DateTime.test.ts b/tests/iso-date/DateTime.test.ts index a20569385..877603f0e 100644 --- a/tests/iso-date/DateTime.test.ts +++ b/tests/iso-date/DateTime.test.ts @@ -128,6 +128,7 @@ describe('GraphQLDateTime', () => { }; it(`parses literal ${stringify(literal)} into javascript Date ${stringify(expected)}`, () => { + // @ts-expect-error - intentional invalid input expect(GraphQLDateTime.parseLiteral(literal, {})).toEqual(expected); }); }); @@ -139,6 +140,7 @@ describe('GraphQLDateTime', () => { }; it(`errors when parsing invalid literal ${stringify(invalidLiteral)}`, () => { expect(() => + // @ts-expect-error - intentional invalid input GraphQLDateTime.parseLiteral(invalidLiteral, {}), ).toThrowErrorMatchingSnapshot(); });