diff --git a/lib/auto.js b/lib/auto.js index 61868070a..eca7d5311 100644 --- a/lib/auto.js +++ b/lib/auto.js @@ -137,7 +137,8 @@ export default function (tasks, concurrency, callback) { arrayEach(dependencies, function (dependencyName) { if (!tasks[dependencyName]) { throw new Error('async.auto task `' + key + - '` has a non-existent dependency in ' + + '` has a non-existent dependency `' + + dependencyName + '` in ' + dependencies.join(', ')); } addListener(dependencyName, function () { diff --git a/mocha_test/auto.js b/mocha_test/auto.js index 55f3b253f..e2e55f9f3 100644 --- a/mocha_test/auto.js +++ b/mocha_test/auto.js @@ -286,7 +286,7 @@ describe('auto', function () { callback(null, 'task1'); }] }); - }).to.throw(); + }).to.throw(/dependency `noexist`/); done(); });