Skip to content

Commit e11c484

Browse files
committed
feat: migrate testing-library/jest-dom
1 parent 6b2037c commit e11c484

File tree

3 files changed

+8
-10
lines changed

3 files changed

+8
-10
lines changed

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@
9494
"@octokit/types": "11.1.0",
9595
"@playwright/test": "1.37.1",
9696
"@tailwindcss/typography": "0.5.9",
97-
"@testing-library/jest-dom": "6.0.1",
97+
"@testing-library/jest-dom": "6.1.2",
9898
"@testing-library/react": "14.0.0",
9999
"@types/node": "18.17.6",
100100
"@types/react": "18.2.20",

pnpm-lock.yaml

+4-4
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vitest.setup.mjs

+3-5
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
1-
import matchers from '@testing-library/jest-dom/matchers'
2-
import { cleanup } from '@testing-library/react'
3-
import { expect, afterEach } from 'vitest'
1+
import '@testing-library/jest-dom/vitest'
42

5-
// extends Vitest's expect method with methods from react-testing-library
6-
expect.extend(matchers)
3+
import { cleanup } from '@testing-library/react'
4+
import { afterEach } from 'vitest'
75

86
// runs a cleanup after each test case (e.g. clearing jsdom)
97
afterEach(() => {

0 commit comments

Comments
 (0)