dillon1000/react

Commit

Make ReactEventTopLevelCallback-test pass

This module-level mock() seems to have been interfering with other tests (26 specs failing). We don't have any other tests that do a module-level mock() so I'm going to assume it isn't supported in the open-source test runner right now. I changed it so only ReactEventEmitter.handleTopLevel is mocked; doing so made ReactEventEmitter complain that TopLevelCallbackCreator wasn't defined so I switched the ReactMount references to use React directly so that ReactDefaultInjection would kick in properly.

With this, all the tests pass.
Browse files
Changed paths1 file
First-parent comparison
M src/core/__tests__/ReactEventTopLevelCallback-test.js Modified
Patch

Files changed

Rendering syntax-highlighted changes…