1
0
mirror of https://github.com/yldio/copilot.git synced 2024-12-11 04:20:05 +02:00
copilot/frontend/test/_hook.js

17 lines
465 B
JavaScript
Raw Normal View History

2016-12-14 00:09:04 +02:00
const hook = require('node-hook');
2016-12-20 13:29:54 +02:00
const jsdom = require('jsdom');
2016-12-14 00:09:04 +02:00
const register = require('babel-register');
hook.hook('.png', () => '');
register({
extensions: ['.js']
});
2016-12-20 13:29:54 +02:00
// import ExecutionEnvironment from 'react/lib/ExecutionEnvironment';
if (!global.document || !global.window) {
global.document = jsdom.jsdom('<!doctype html><html><body></body></html>');
global.window = global.document.defaultView;
global.navigator = global.window.navigator;
}