We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
@testing-library/jest-dom
node
jest
vitest
npm
yarn
react-testing-library
tsconfig.json (for NextJS project):
{ "compilerOptions": { "target": "ES2020", "lib": ["dom", "dom.iterable", "esnext"], "allowJs": true, "skipLibCheck": true, "strict": true, "forceConsistentCasingInFileNames": true, "noEmit": true, "esModuleInterop": true, "module": "esnext", "moduleResolution": "node", "resolveJsonModule": true, "isolatedModules": true, "jsx": "preserve", "incremental": true, "allowUnreachableCode": false, "allowUnusedLabels": false, "declaration": true, "noFallthroughCasesInSwitch": true, "noImplicitReturns": true, "pretty": true, "sourceMap": true, "plugins": [ { "name": "next" } ], "paths": { "@/*": ["./src/*"] } }, "include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"], "exclude": ["node_modules", "stories"] }
We updated jest-dom to v6 from v5. Then we run tsc --pretty --noEmit.
tsc --pretty --noEmit
All test statements were no longer recognized:
I really don't have the time to make a new repo with minimal repro steps, but I hope the information I gave will suffice.
The text was updated successfully, but these errors were encountered:
FWIW: I had a similar issue and I had to add the include vitest/globals as part of the compilerOptions.types. Here's my tsconfig.json.
vitest/globals
compilerOptions.types
tsconfig.json
{ "compilerOptions": { "target": "esnext", "useDefineForClassFields": true, "lib": ["dom", "dom.iterable", "esnext"], "allowJs": false, "skipLibCheck": true, "esModuleInterop": false, "allowSyntheticDefaultImports": true, "strict": true, "forceConsistentCasingInFileNames": true, "noFallthroughCasesInSwitch": true, "module": "esnext", "moduleResolution": "node", "resolveJsonModule": true, "isolatedModules": true, "noEmit": true, "jsx": "react-jsx", "baseUrl": "src", "types": [ "vitest/globals", "vite/client", "node", "@testing-library/jest-dom" ] }, "include": ["src"] }
Hope it's helpful :)
Sorry, something went wrong.
No branches or pull requests
@testing-library/jest-dom
version: 6.1.3node
version: 18.0.0jest
(orvitest
) version: 29.6.2npm
(oryarn
) version: 9.5.1react-testing-library
version: 14.0.0Relevant code or config:
tsconfig.json (for NextJS project):
What you did:
We updated jest-dom to v6 from v5.
Then we run
tsc --pretty --noEmit
.What happened:
All test statements were no longer recognized:
I really don't have the time to make a new repo with minimal repro steps, but I hope the information I gave will suffice.
The text was updated successfully, but these errors were encountered: