From 86f3852b68545a6c7db45021ba05484cd15a372b Mon Sep 17 00:00:00 2001 From: Aaron Raddon Date: Wed, 13 Jul 2016 08:33:23 -0700 Subject: [PATCH] Add test for Date format w a Z --- parseany_test.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/parseany_test.go b/parseany_test.go index af0e10c..a84e96d 100644 --- a/parseany_test.go +++ b/parseany_test.go @@ -231,6 +231,11 @@ func TestParse(t *testing.T) { //u.Debug(ts.In(time.UTC).Unix(), ts.In(time.UTC)) assert.T(t, "2009-08-13 05:15:09 +0000 UTC" == fmt.Sprintf("%v", ts.In(time.UTC))) + ts, err = ParseAny("2009-08-12T22:15:09Z") + assert.Tf(t, err == nil, "%v", err) + //u.Debug(ts.In(time.UTC)) + assert.T(t, "2009-08-12 22:15:09 +0000 UTC" == fmt.Sprintf("%v", ts.In(time.UTC))) + ts, err = ParseAny("2009-08-12T22:15:09") assert.Tf(t, err == nil, "%v", err) //u.Debug(ts.In(time.UTC))