From f5a0465b10f0e305b7b53d2631caa67db55e2036 Mon Sep 17 00:00:00 2001 From: harttle Date: Mon, 24 Oct 2016 01:31:18 +0800 Subject: [PATCH] fix strftime test --- test/util/strftime.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/test/util/strftime.js b/test/util/strftime.js index 33fd84487..7cb3dfe24 100644 --- a/test/util/strftime.js +++ b/test/util/strftime.js @@ -8,7 +8,10 @@ describe('util/strftime', function() { it('should format week by %U', function() { expect(t(now, '%U')).to.equal('43'); }); - it('should format GMT string', function() { - expect(t(now, '%Y-%m-%dT%H:%M:%S')).to.equal('2016-10-24T00:15:23'); + it('should format locale date string', function() { + expect(t(now, '%Y-%m-%d')).to.equal(now.toLocaleDateString()); + }); + it('should format locale date string', function() { + expect(t(now, '%H:%M:%S')).to.equal(now.toLocaleTimeString()); }); });