diff options
Diffstat (limited to 'test/service')
| -rw-r--r-- | test/service/qSpec.js | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/service/qSpec.js b/test/service/qSpec.js index e592ab87..a230d1de 100644 --- a/test/service/qSpec.js +++ b/test/service/qSpec.js @@ -676,6 +676,14 @@ describe('q', function() { describe('all', function() { + it('should resolve all of nothing', function() { + var result; + q.all([]).then(function(r) { result = r; }); + mockNextTick.flush(); + expect(result).toEqual([]); + }); + + it('should take an array of promises and return a promise for an array of results', function() { var deferred1 = defer(), deferred2 = defer(); |
