-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Closed
Labels
Description
@testing-library/react
version: 16.1.0- Testing Framework and version:
Vitest 2.0.5 - DOM Environment:
JSDOM 25.0.1
Relevant code or config:
npm run update;
What you did:
Updated @testing-library/react from 16.0.1 to 16.1.0
What happened:
My tests using @testing-library/react started throwing errors.
Error: A React Element from an older version of React was rendered. This is not supported. It can happen if:
- Multiple copies of the "react" package is used.
- A library pre-bundled an old copy of "react" or "react/jsx-runtime".
- A compiler tries to "inline" JSX instead of using the runtime.
Problem description:
Not sure if it's a general issue or specific to our usage. We are only using it in one test file, and the methods we are importing and using are act, renderHook, waitFor
.
domdomegg