diff options
author | Aydar Zartdinov <zartdinov@gmail.com> | 2015-07-09 15:44:30 +0300 |
---|---|---|
committer | Aydar Zartdinov <zartdinov@gmail.com> | 2015-07-09 15:44:30 +0300 |
commit | 173e9133c064aaa22a699ba038754c5994783733 (patch) | |
tree | 1d317e6d18bc2ce08bfeddf790748cc62a8ceaa2 /test | |
parent | 458c73cbd16100a28d60e8fefc9cd15447b19725 (diff) | |
download | async-173e9133c064aaa22a699ba038754c5994783733.tar.gz |
unit test for NPO
Diffstat (limited to 'test')
-rwxr-xr-x | test/test-async.js | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/test/test-async.js b/test/test-async.js index 3e237c6..844bce9 100755 --- a/test/test-async.js +++ b/test/test-async.js @@ -4269,8 +4269,16 @@ exports['asyncify'] = { } }, - 'promisified': ['bluebird', 'es6-promise', 'rsvp'].reduce(function(promises, name) { - var Promise = require(name).Promise; + 'promisified': [ + 'native-promise-only', + 'bluebird', + 'es6-promise', + 'rsvp' + ].reduce(function(promises, name) { + var Promise = require(name); + if (typeof Promise.Promise === 'function') { + Promise = Promise.Promise; + } promises[name] = { 'resolve': function(test) { var promisified = function(argument) { |