diff --git a/.changeset/breezy-grapes-suffer.md b/.changeset/breezy-grapes-suffer.md new file mode 100644 index 00000000000..1daafefeab5 --- /dev/null +++ b/.changeset/breezy-grapes-suffer.md @@ -0,0 +1,5 @@ +--- +"@fast-check/vitest": patch +--- + +🚨(vitest) Abide by lint rule `no-duplicate-type-constituents` diff --git a/packages/vitest/src/internals/TestBuilder.ts b/packages/vitest/src/internals/TestBuilder.ts index b451de11ba9..ce4209f905e 100644 --- a/packages/vitest/src/internals/TestBuilder.ts +++ b/packages/vitest/src/internals/TestBuilder.ts @@ -69,18 +69,15 @@ function adaptRunDetailsForRecord( * @param testFn - The source `{it,test}.*` */ function buildTestProp( - // eslint-disable-next-line @typescript-eslint/no-duplicate-type-constituents - testFn: It | It['only' | 'skip' | 'concurrent'] | It['concurrent']['only' | 'skip'], + testFn: It | It['only' | 'skip' | 'concurrent'], fc: FcExtra, ): TestPropTuple; function buildTestProp( - // eslint-disable-next-line @typescript-eslint/no-duplicate-type-constituents - testFn: It | It['only' | 'skip' | 'concurrent'] | It['concurrent']['only' | 'skip'], + testFn: It | It['only' | 'skip' | 'concurrent'], fc: FcExtra, ): TestPropRecord; function buildTestProp( - // eslint-disable-next-line @typescript-eslint/no-duplicate-type-constituents - testFn: It | It['only' | 'skip' | 'concurrent'] | It['concurrent']['only' | 'skip'], + testFn: It | It['only' | 'skip' | 'concurrent'], fc: FcExtra, ): TestPropTuple | TestPropRecord { return (arbitraries, params?: FcParameters) => { diff --git a/packages/vitest/src/internals/TestWithPropRunnerBuilder.ts b/packages/vitest/src/internals/TestWithPropRunnerBuilder.ts index 6d7dba9d518..8442d36f9f1 100644 --- a/packages/vitest/src/internals/TestWithPropRunnerBuilder.ts +++ b/packages/vitest/src/internals/TestWithPropRunnerBuilder.ts @@ -8,8 +8,7 @@ function wrapProp(prop: Prop): PromiseProp { } export function buildTestWithPropRunner( - // eslint-disable-next-line @typescript-eslint/no-duplicate-type-constituents - testFn: It | It['only' | 'skip' | 'concurrent'] | It['concurrent']['only' | 'skip'], + testFn: It | It['only' | 'skip' | 'concurrent'], label: string, arbitraries: ArbitraryTuple, prop: Prop,