43 lines
881 B
JavaScript
43 lines
881 B
JavaScript
process.on('warning', warning => {
|
|
console.log(warning.name);
|
|
console.log(warning.message);
|
|
console.log(warning.stack);
|
|
});
|
|
|
|
var verbose = false;
|
|
|
|
if (process.argv[2] === '--v') {
|
|
verbose = true;
|
|
}
|
|
servicesDir = `${__dirname}/services/db`;
|
|
|
|
var Jasmine = require('jasmine');
|
|
var jasmine = new Jasmine();
|
|
var SpecReporter = require('jasmine-spec-reporter').SpecReporter;
|
|
let environment = require('gulp-env');
|
|
|
|
environment(".env.json");
|
|
|
|
let serviceSpecs = [
|
|
'db/tests/**/*[sS]pec.js'
|
|
];
|
|
|
|
jasmine.loadConfig({
|
|
spec_dir: 'services',
|
|
spec_files: serviceSpecs,
|
|
helpers: [
|
|
'/services/utils/jasmineHelpers.js'
|
|
]
|
|
});
|
|
|
|
jasmine.addReporter(new SpecReporter({
|
|
spec: {
|
|
// displayStacktrace: 'summary',
|
|
displaySuccessful: verbose,
|
|
displayFailedSpec: true,
|
|
displaySpecDuration: true
|
|
}
|
|
}));
|
|
|
|
jasmine.execute();
|