Skip to content

Commit

Permalink
nit: a quick copy edit for an act() message/comment (#15805)
Browse files Browse the repository at this point in the history
  • Loading branch information
Sunil Pai committed Jun 4, 2019
1 parent cfb79ee commit d707a75
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions packages/react-reconciler/src/ReactFiberWorkLoop.js
Original file line number Diff line number Diff line change
Expand Up @@ -2388,17 +2388,14 @@ export function warnIfNotScopedWithMatchingAct(fiber: Fiber): void {
if (__DEV__) {
if (
ReactCurrentActingRendererSigil.current !== null &&
// use the function flushPassiveEffects directly as the sigil
// so this comparison is expected here
ReactCurrentActingRendererSigil.current !== ReactActingRendererSigil
) {
// it looks like we're using the wrong matching act(), so log a warning
warningWithoutStack(
false,
"It looks like you're using the wrong act() around your test interactions.\n" +
'Be sure to use the matching version of act() corresponding to your renderer:\n\n' +
'// for react-dom:\n' +
"import {act} from 'react-test-utils';\n" +
"import {act} from 'react-dom/test-utils';\n" +
'//...\n' +
'act(() => ...);\n\n' +
'// for react-test-renderer:\n' +
Expand Down

0 comments on commit d707a75

Please sign in to comment.