From dba518999dfb7212f6fbc42d85dd303fcb78baad Mon Sep 17 00:00:00 2001 From: Jorropo Date: Mon, 5 Feb 2024 01:22:58 +0100 Subject: [PATCH] time: fix FuzzFormatRFC3339 nano comparison Change-Id: I13ed84b99459d5844abb6e932cc4b8e0bd3ae9f5 Reviewed-on: https://go-review.googlesource.com/c/go/+/561215 LUCI-TryBot-Result: Go LUCI Reviewed-by: Ian Lance Taylor Auto-Submit: Ian Lance Taylor Reviewed-by: David Chase --- src/time/format_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/time/format_test.go b/src/time/format_test.go index 8a26eaa35b..29b9c280e6 100644 --- a/src/time/format_test.go +++ b/src/time/format_test.go @@ -1001,7 +1001,7 @@ func FuzzFormatRFC3339(f *testing.F) { gotNanos := AppendFormatRFC3339(ts, nil, true) wantNanos := AppendFormatAny(ts, nil, RFC3339Nano) - if !bytes.Equal(got, want) { + if !bytes.Equal(gotNanos, wantNanos) { t.Errorf("Format(%s, RFC3339Nano) mismatch:\n\tgot: %s\n\twant: %s", ts, gotNanos, wantNanos) } }) -- 2.48.1