diff options
author | Alex Early <alexander.early@gmail.com> | 2018-07-10 20:57:10 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-07-10 20:57:10 -0700 |
commit | bf7f054ca8801d4540fe49f7a4bb5d0575a53769 (patch) | |
tree | df0154002fa0d56153b46df65aea39ec5e79d8f9 /test/es2017/asyncFunctions.js | |
parent | 00fe45e092fa1bb1f4c27d078c7a467f53e17b03 (diff) | |
download | async-bf7f054ca8801d4540fe49f7a4bb5d0575a53769.tar.gz |
breaking: remove during, make test functions in until/whilst async (#1557)
* remove during, make test functions in until/whilst async
* add during aliases fix docs
* regenerate index
Diffstat (limited to 'test/es2017/asyncFunctions.js')
-rw-r--r-- | test/es2017/asyncFunctions.js | 30 |
1 files changed, 4 insertions, 26 deletions
diff --git a/test/es2017/asyncFunctions.js b/test/es2017/asyncFunctions.js index 22468f8..680725b 100644 --- a/test/es2017/asyncFunctions.js +++ b/test/es2017/asyncFunctions.js @@ -412,31 +412,9 @@ module.exports = function () { }); }); - it('should handle async functions in during', (done) => { - var val = 0; - async.during(async () => { - return val < 3; - }, - async () => { - val += 1; - return val; - }, done); - }); - - it('should handle async functions in doDuring', (done) => { - var val = 0; - async.doDuring(async () => { - val += 1; - return val; - }, - async (res) => { - return res < 3; - }, done); - }); - it('should handle async functions in whilst', (done) => { var val = 0; - async.whilst(() => val < 3, + async.whilst(async () => val < 3, async () => { val += 1; return val; @@ -448,12 +426,12 @@ module.exports = function () { async.doWhilst(async () => { val += 1; return val; - }, (res) => res < 3, done); + }, async (res) => res < 3, done); }); it('should handle async functions in until', (done) => { var val = 0; - async.until(() => val > 3, + async.until(async () => val > 3, async () => { val += 1; return val; @@ -465,7 +443,7 @@ module.exports = function () { async.doUntil(async () => { val += 1; return val; - }, (res) => res > 3, done); + }, async (res) => res > 3, done); }); it('should handle async functions in forever', (done) => { |