From e97a524cf1f6b8b1782249f343f94c5525adb663 Mon Sep 17 00:00:00 2001 From: Menghan Li Date: Wed, 17 Aug 2016 17:21:51 -0700 Subject: [PATCH] Fix go 1.7 vet --- transport/transport_test.go | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/transport/transport_test.go b/transport/transport_test.go index efe35a6b..2c2f1f66 100644 --- a/transport/transport_test.go +++ b/transport/transport_test.go @@ -39,7 +39,6 @@ import ( "io" "math" "net" - "reflect" "strconv" "sync" "testing" @@ -754,11 +753,11 @@ func TestEncodingRequiredStatus(t *testing.T) { } func TestStreamContext(t *testing.T) { - expectedStream := Stream{} - ctx := newContextWithStream(context.Background(), &expectedStream) + expectedStream := &Stream{} + ctx := newContextWithStream(context.Background(), expectedStream) s, ok := StreamFromContext(ctx) - if !ok || !reflect.DeepEqual(expectedStream, *s) { - t.Fatalf("GetStreamFromContext(%v) = %v, %t, want: %v, true", ctx, *s, ok, expectedStream) + if !ok || expectedStream != s { + t.Fatalf("GetStreamFromContext(%v) = %v, %t, want: %v, true", ctx, s, ok, expectedStream) } }