aboutsummaryrefslogtreecommitdiffstats
path: root/test/ngMock/angular-mocksSpec.js
diff options
context:
space:
mode:
authorDaniel Luxemburg2014-02-03 20:04:46 -0500
committerTobias Bosch2014-02-04 16:41:25 -0800
commitdd24c78373b5d24ecb3b9d19e61e1b3b6c74d155 (patch)
tree7e0de9522b19e920ab6994da83e2b163c80cf0f3 /test/ngMock/angular-mocksSpec.js
parent36d37c0e3880c774d20c014ade60d2331beefa15 (diff)
downloadangular.js-dd24c78373b5d24ecb3b9d19e61e1b3b6c74d155.tar.bz2
fix(ngMock): return false from mock $interval.cancel() when no argument is supplied
Closes #6103. Closed #6099.
Diffstat (limited to 'test/ngMock/angular-mocksSpec.js')
-rw-r--r--test/ngMock/angular-mocksSpec.js5
1 files changed, 5 insertions, 0 deletions
diff --git a/test/ngMock/angular-mocksSpec.js b/test/ngMock/angular-mocksSpec.js
index e5f67a7e..c2b6108d 100644
--- a/test/ngMock/angular-mocksSpec.js
+++ b/test/ngMock/angular-mocksSpec.js
@@ -509,6 +509,11 @@ describe('ngMock', function() {
it('should not throw a runtime exception when given an undefined promise',
inject(function($interval) {
+ var task1 = jasmine.createSpy('task1'),
+ promise1;
+
+ promise1 = $interval(task1, 1000, 1);
+
expect($interval.cancel()).toBe(false);
}));
});