aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/ngMock/angular-mocksSpec.js11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/ngMock/angular-mocksSpec.js b/test/ngMock/angular-mocksSpec.js
index d80b1976..c656e940 100644
--- a/test/ngMock/angular-mocksSpec.js
+++ b/test/ngMock/angular-mocksSpec.js
@@ -63,6 +63,17 @@ describe('ngMock', function() {
});
+ it('should fake toISOString method', function() {
+ var date = new angular.mock.TzDate(-1, '2009-10-09T01:02:03.027Z');
+
+ if (new Date().toISOString) {
+ expect(date.toISOString()).toEqual('2009-10-09T01:02:03.027Z');
+ } else {
+ expect(date.toISOString).toBeUndefined();
+ }
+ });
+
+
it('should fake getHours method', function() {
//0 in -3h
var t0 = new angular.mock.TzDate(-3, 0);