Browse Source

Merge pull request #334 from ariporad/fix-bluebird-warnings

Fix bluebird warnings
babel-plugin-for-integration-tests
Sindre Sorhus 9 years ago
parent
commit
4513cba264
  1. 7
      api.js

7
api.js

@ -140,8 +140,8 @@ Api.prototype.run = function () {
// receive test count from all files and then run the tests
var statsCount = 0;
var deferred = Promise.pending();
return new Promise(function (resolve) {
tests.forEach(function (test) {
var counted = false;
@ -155,7 +155,7 @@ Api.prototype.run = function () {
var method = self.options.serial ? 'mapSeries' : 'map';
deferred.resolve(Promise[method](files, function (file, index) {
resolve(Promise[method](files, function (file, index) {
return tests[index].run();
}));
}
@ -164,8 +164,7 @@ Api.prototype.run = function () {
test.on('stats', tryRun);
test.catch(tryRun);
});
return deferred.promise;
});
})
.then(function (results) {
// assemble stats from all tests

Loading…
Cancel
Save