Skip to content
New issue

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

Slide effect not pass react test #129

Closed
AREEG94FAHAD opened this issue Apr 3, 2021 · 6 comments
Closed

Slide effect not pass react test #129

AREEG94FAHAD opened this issue Apr 3, 2021 · 6 comments

Comments

@AREEG94FAHAD
Copy link

I am try to pass react test but this appear to me when i use slide effect

TypeError: Cannot read property 'querySelectorAll' of null

  10 | it('renders correctly', () => {
  11 |   const tree = renderer
> 12 |     .create(
     |      ^
  13 |       <Provider store={store}>
  14 |         <Router>
  15 |           <Home store={store} />
@femioladeji
Copy link
Owner

@AREEG94FAHAD are you saying your test is failing because of the package? Can you try and log the test-mounted HTML? Also what testing framework are you using

@AREEG94FAHAD
Copy link
Author

I am using this test
https://www.npmjs.com/package/react-test-renderer
when I remove Slid component it work fine.
I don't understand this
"Can you try and log the test-mounted HTML"

@femioladeji
Copy link
Owner

@AREEG94FAHAD I've been able to replicate the bug. I'll push a fix soon. Thanks for reporting this

@femioladeji
Copy link
Owner

After a bit of digging, I discovered this is an issue with react-test-renderer not working well with refs as noted in this issue facebook/react#7740

I'll try and look for a way to fix the bug

@AREEG94FAHAD
Copy link
Author

Awesome I really I appreciate your effort

@femioladeji
Copy link
Owner

@AREEG94FAHAD I've released a new version that fixes the issue. Can you install v3.4.6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants