Mailspring/spec/n1-spec-runner/spec-bootstrap.es6
2016-11-15 16:49:11 -08:00

18 lines
657 B
JavaScript

/* eslint import/imports-first: 0 */
// Swap out Node's native Promise for Bluebird, which allows us to
// do fancy things like handle exceptions inside promise blocks
global.Promise = require('bluebird');
Promise.longStackTraces();
import NylasEnvConstructor from '../../src/nylas-env';
window.NylasEnv = NylasEnvConstructor.loadOrCreate();
NylasEnv.initialize();
const loadSettings = NylasEnv.getLoadSettings();
// This must be `required` instead of imported because
// NylasEnv.initialize() must complete before `nylas-exports` and other
// globals are available for import via es6 modules.
require('./n1-spec-runner').default.runSpecs(loadSettings)