2015-05-22 06:46:36 +02:00
|
|
|
import document from 'global/document';
|
2015-04-29 23:05:22 +02:00
|
|
|
import window from 'global/window';
|
|
|
|
import sinon from 'sinon';
|
|
|
|
|
|
|
|
window.q = QUnit;
|
|
|
|
window.sinon = sinon;
|
|
|
|
|
2015-07-08 00:27:20 +02:00
|
|
|
// There's nowhere we require completing xhr requests
|
|
|
|
// and raynos/xhr doesn't want to make stubbing easy (Raynos/xhr#11)
|
|
|
|
// so we need to stub XHR before the xhr module is included anywhere else.
|
|
|
|
window.xhr = sinon.useFakeXMLHttpRequest();
|
|
|
|
|
2015-04-29 23:05:22 +02:00
|
|
|
// This may not be needed anymore, but double check before removing
|
|
|
|
window.fixture = document.createElement('div');
|
2015-05-22 06:46:36 +02:00
|
|
|
window.fixture.id = 'qunit-fixture';
|
|
|
|
document.body.appendChild(window.fixture);
|