From 025c92190376414c15f15fd20a75b41489a4e70a Mon Sep 17 00:00:00 2001 From: Henning Teek Date: Fri, 23 Aug 2013 12:48:32 +0200 Subject: fix(dateFilter): allow negative millisecond value strings --- test/ng/filter/filtersSpec.js | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'test') diff --git a/test/ng/filter/filtersSpec.js b/test/ng/filter/filtersSpec.js index 59883799..cd83437f 100644 --- a/test/ng/filter/filtersSpec.js +++ b/test/ng/filter/filtersSpec.js @@ -246,6 +246,10 @@ describe('filters', function() { toEqual('September 03, 1'); }); + it('should accept negative numbers as strings', function() { + expect(date('-1')).toEqual('Dec 31, 1969'); + }); + it('should format timezones correctly (as per ISO_8601)', function() { //Note: TzDate's first argument is offset, _not_ timezone. var utc = new angular.mock.TzDate( 0, '2010-09-03T12:05:08.000Z'); -- cgit v1.2.3