npm install
Run:
npm test
Expected result: The test passes and the console logs componentDidUpdate
What actually happens: The test fails and nothing is logged from lifecycle methods
Open scripts/Foo.test.jsx and uncomment the other test scenarios. These work as expected. There are two other scenarios:
- Using
mount
to render the component - Using
shallow
to render the component and passing inlifecycleExperimental: true
as an option (which should be the default according to the docs)