Skip to content

Commit

Permalink
adjust vitest ambient declaration file according to vitest docs (#612)
Browse files Browse the repository at this point in the history
Co-authored-by: Ernesto García <ernesto@ernesto.dev>
  • Loading branch information
vorant94 and gnapse authored Jul 24, 2024
1 parent a073b08 commit 06d19ba
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions types/vitest.d.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
import {type expect} from 'vitest'
import {type TestingLibraryMatchers} from './matchers'

export {}
declare module '@vitest/expect' {
interface JestAssertion<T = any>
declare module 'vitest' {
interface Assertion<T = any>
extends TestingLibraryMatchers<
ReturnType<typeof expect.stringContaining>,
T
> {}
interface AsymmetricMatchersContaining
extends TestingLibraryMatchers<
ReturnType<typeof expect.stringContaining>,
any
> {}
}

0 comments on commit 06d19ba

Please # to comment.