-
Notifications
You must be signed in to change notification settings - Fork 70
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Problem
For some reason, when using Sentry.captureException(error) in the ProfileImageInfo component, the storyshots test throw:
Ran all test suites matching /__tests__\/storyshots.test.js/i.
console.error
Warning: An update to DiscordBar inside a test was not wrapped in act(...).
When testing, code that causes React state updates should be wrapped into act(...):
act(() => {
/* fire events that update state */
});
/* assert on the output */
This ensures that you're testing the behavior the user would see in the browser. Learn more at https://reactjs.org/link/wrap-tests-with-act
at DiscordBar (c0d3-app/components/DiscordBar.tsx:740:12)
at div
at div
at div
at Layout (c0d3-app/components/Layout.tsx:205:3)
at Curriculum (c0d3-app/pages/curriculum.tsx:1761:3)
at ApolloProvider (c0d3-app/node_modules/@apollo/client/react/context/ApolloProvider.js:5:21)
at MockedProvider (c0d3-app/node_modules/@apollo/client/utilities/testing/mocking/MockedProvider.js:10:28)
at storyFn
It seems to be related to #715
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working