Skip to content

Commit

Permalink
Add a test that Q.all modifies the input array.
Browse files Browse the repository at this point in the history
  • Loading branch information
domenic committed May 18, 2013
1 parent 686637c commit 9ab54a1
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions spec/q-spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -1120,6 +1120,15 @@ describe("all", function () {
});
});

it("modifies the input array", function () {
var input = [Q.resolve(0), Q.resolve(1)];

return Q.all(input).then(function (result) {
expect(result).toBe(input);
expect(input).toEqual([0, 1]);
});
});

});

describe("allResolved", function () {
Expand Down

0 comments on commit 9ab54a1

Please sign in to comment.