You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After updating to the latest version, I got this error in my tests (in all of them which use react testing library):
Trying to detect host component names triggered the following error:
Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: undefined. You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.
Check the render method of `ForwardRef(Switch)`.
There seems to be an issue with your configuration that prevents React Native Testing Library from working correctly.
Please check if you are using compatible versions of React Native and React Native Testing Library.
The thing is I'm not using the Switch component anywhere in my app nor the tests, I've been using this patch to workaround it:
Describe the bug
After updating to the latest version, I got this error in my tests (in all of them which use react testing library):
The thing is I'm not using the
Switch
component anywhere in my app nor the tests, I've been using this patch to workaround it:Expected behavior
This error should not happen
Steps to Reproduce
N/A
Screenshots
N/A
Versions
@testing-library/react-native: 12.8.1 => 12.8.1
react: 18.3.1 => 18.3.1
react-native: 0.76.1 => 0.76.1
The text was updated successfully, but these errors were encountered: