Skip to content

Commit fa8fc9d

Browse files
committed
test(plugin-typescript): refine tests
1 parent 0888cc5 commit fa8fc9d

File tree

1 file changed

+6
-9
lines changed

1 file changed

+6
-9
lines changed

packages/plugin-typescript/src/lib/schema.unit.test.ts

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -59,14 +59,11 @@ describe('typescriptPluginConfigSchema', () => {
5959
});
6060

6161
it('throws for unknown audit slug', () => {
62-
expect(
63-
() =>
64-
typescriptPluginConfigSchema.parse({
65-
tsConfigPath,
66-
onlyAudits: ['unknown-audit'],
67-
}),
68-
// Message too large because enums validation
69-
// eslint-disable-next-line vitest/require-to-throw-message
70-
).toThrow();
62+
expect(() =>
63+
typescriptPluginConfigSchema.parse({
64+
tsConfigPath,
65+
onlyAudits: ['unknown-audit'],
66+
}),
67+
).toThrow(/unknown-audit/);
7168
});
7269
});

0 commit comments

Comments
 (0)