react-native/Libraries/WebSocket/__mocks__/event-target-shim.js
Christopher Chedeau 6f84ccf51a Fix tests related to event-target-shim
Summary: @​public

Jest has an issue where if you export `Symbol` it crashes badly. Since event-target-shim does that, it breaks everything. Mocking that module fixes the issue until @cpojer comes back from vacation and fixes the bug in Jest itself.

Reviewed By: @jingc

Differential Revision: D2503562
2015-10-02 12:36:23 -07:00

10 lines
233 B
JavaScript

// Jest fatals for the following statement (minimal repro case)
//
// exports.something = Symbol;
//
// Until it is fixed, mocking the entire node module makes the
// problem go away.
'use strict';
module.exports = function() {};