From 914f08f4d8a0317bc7d3ef59ee2ae05e6e02615f Mon Sep 17 00:00:00 2001 From: Derk-Jan Karrenbeld Date: Wed, 31 Jul 2024 22:54:22 +0200 Subject: [PATCH] Fix ts-expect-error (should not be there) --- test/fixtures/tstyche/documentation/__typetests__/docs.tst.ts | 1 - test/types.test.mjs | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/test/fixtures/tstyche/documentation/__typetests__/docs.tst.ts b/test/fixtures/tstyche/documentation/__typetests__/docs.tst.ts index 5d2266d..c6884c4 100644 --- a/test/fixtures/tstyche/documentation/__typetests__/docs.tst.ts +++ b/test/fixtures/tstyche/documentation/__typetests__/docs.tst.ts @@ -7,7 +7,6 @@ function firstItem(target: Array): T | undefined { test("first item requires a parameter", () => { expect(firstItem(["a", "b", "c"])).type.toBe(); - // @ts-expect-error expect(firstItem()).type.toRaiseError("Expected 1 argument"); }); diff --git a/test/types.test.mjs b/test/types.test.mjs index 7f06904..6cdc561 100644 --- a/test/types.test.mjs +++ b/test/types.test.mjs @@ -4,7 +4,7 @@ import { assertError, assertPass } from './asserts.mjs' import { fixtures } from './paths.mjs' shelljs.echo('type tests (only) > documentation solution (smoke test)') -assertError('tstyche', join(fixtures, 'tstyche', 'documentation')) +assertPass('tstyche', join(fixtures, 'tstyche', 'documentation')) shelljs.echo('type tests (only) > failing solution') assertError('tstyche', join(fixtures, 'tstyche', 'fire'))