koel/resources/assets/js/tests/setup.js
2017-12-28 21:48:34 +01:00

17 lines
457 B
JavaScript

// setup JSDOM
require('jsdom-global')()
// make sure polyfill is loaded before generators
require('babel-polyfill')
require('chai').should()
// make common utils available globally as well
global.Vue = require('vue')
global.expect = require('expect')
global.sinon = require('sinon')
global._ = require('lodash')
const testUtils = require('vue-test-utils')
global.shallow = testUtils.shallow
global.mount = testUtils.mount
window.__UNIT_TESTING__ = true