소스 검색

Change TestMarshalDate to work with UTC to avoid TZ errors (#1169)

Signed-off-by: Alex Lourie <alex@instaclustr.com>
Alex Lourie 7 년 전
부모
커밋
db20ccb043
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      marshal_test.go

+ 1 - 1
marshal_test.go

@@ -1358,7 +1358,7 @@ func TestUnmarshalDate(t *testing.T) {
 }
 
 func TestMarshalDate(t *testing.T) {
-	now := time.Now()
+	now := time.Now().UTC()
 	timestamp := now.UnixNano() / int64(time.Millisecond)
 	expectedData := encInt(int32(timestamp/86400000 + int64(1<<31)))
 	var marshalDateTests = []struct {