2016-06-01 07:59:15 +03:00
|
|
|
import 'polyfills';
|
|
|
|
|
2016-07-30 13:44:43 +03:00
|
|
|
import expect from 'unexpected';
|
|
|
|
expect.use(require('unexpected-sinon'));
|
|
|
|
|
2016-12-04 14:11:23 +02:00
|
|
|
if (!window.localStorage) {
|
|
|
|
window.localStorage = {
|
|
|
|
getItem(key) {
|
2016-12-05 21:14:38 +02:00
|
|
|
return this[key] || null;
|
2016-12-04 14:11:23 +02:00
|
|
|
},
|
|
|
|
setItem(key, value) {
|
|
|
|
this[key] = value;
|
|
|
|
},
|
|
|
|
removeItem(key) {
|
|
|
|
delete this[key];
|
|
|
|
}
|
|
|
|
};
|
|
|
|
|
|
|
|
window.sessionStorage = {
|
|
|
|
...window.localStorage
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
2016-03-21 08:16:37 +02:00
|
|
|
// require all modules ending in "_test" from the
|
|
|
|
// current directory and all subdirectories
|
2016-07-30 13:44:43 +03:00
|
|
|
const testsContext = require.context('.', true, /\.test\.jsx?$/);
|
2016-03-21 08:16:37 +02:00
|
|
|
testsContext.keys().forEach(testsContext);
|