From 97d4314441d464b9beaf95ffbaa08808cfefd380 Mon Sep 17 00:00:00 2001 From: Patrick Jones Date: Thu, 12 Nov 2020 14:21:10 -0800 Subject: [PATCH] google: remove remaining cmp.Diff call Change-Id: I189302ad4f49a206dd298b767a827b0263df8c43 --- google/internal/externalaccount/sts_exchange.go | 1 - google/internal/externalaccount/sts_exchange_test.go | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/google/internal/externalaccount/sts_exchange.go b/google/internal/externalaccount/sts_exchange.go index 1bcd661..7571a0b 100644 --- a/google/internal/externalaccount/sts_exchange.go +++ b/google/internal/externalaccount/sts_exchange.go @@ -63,7 +63,6 @@ func ExchangeToken(ctx context.Context, endpoint string, request *STSTokenExchan } - return &stsResp, nil } diff --git a/google/internal/externalaccount/sts_exchange_test.go b/google/internal/externalaccount/sts_exchange_test.go index 496bba6..1cd05e7 100644 --- a/google/internal/externalaccount/sts_exchange_test.go +++ b/google/internal/externalaccount/sts_exchange_test.go @@ -81,8 +81,8 @@ func TestExchangeToken(t *testing.T) { t.Fatalf("ExchangeToken failed with error: %v", err) } - if diff := cmp.Diff(expectedToken, *resp); diff != "" { - t.Errorf("mismatched messages received by mock server (-want +got): \n%v", diff) + if expectedToken != *resp { + t.Errorf("mismatched messages received by mock server. \nWant: \n%v\n\nGot:\n%v", expectedToken, *resp) } }