A calm place to write long-form, and publish it to the open social web. skypress.blog/
0

Configure Feed

Select the types of activity you want to include in your feed.

Tests: wrap PostActions presence unmount in act()

The presence-gate test helper called root.unmount() outside act(), which
made React log "An update to Root inside a test was not wrapped in act(...)"
once per test. Wrapping the unmount in act() silences the warnings and keeps
the test output clean. No assertion or behavior change.

+3 -1
+3 -1
src/components/PostActions.presence.test.tsx
··· 50 50 return { 51 51 html: container.innerHTML, 52 52 cleanup: () => { 53 - root.unmount(); 53 + act( () => { 54 + root.unmount(); 55 + } ); 54 56 container.remove(); 55 57 }, 56 58 };