window.chai = require("chai");
window.expect = chai.expect;
window.sinon = require("sinon");
var sinonChai = require("sinon-chai");
chai.use(sinonChai);

require("spec/test-entry");

after(function() {
  require("coverjs-loader").reportHtml();

  var
    coverJsEl = document.querySelector(".coverjs-report"),
    mochaEl = document.querySelector("#mocha");
  if (coverJsEl) { mochaEl.appendChild(coverJsEl); }
});

var sinonChai, fixturesEl;

window.chai = require("chai");
window.expect = window.chai.expect;
window.sinon = require("sinon");
sinonChai = require("sinon-chai");
window.chai.use(sinonChai);

fixturesEl = document.createElement("div");
fixturesEl.setAttribute("id", "fixtures");

require("spec/test-entry");

after(function() {
  var coverJsEl, mochaEl;
  require("coverjs-loader").reportHtml();
  coverJsEl = document.querySelector(".coverjs-report");
  mochaEl = document.querySelector("#mocha");
  if (coverJsEl) { mochaEl.appendChild(coverJsEl); }
});

add fixtures div to document