diff --git a/wrpclient/wrpclient_test.go b/wrpclient/wrpclient_test.go index 49c816a..f803875 100644 --- a/wrpclient/wrpclient_test.go +++ b/wrpclient/wrpclient_test.go @@ -173,7 +173,9 @@ func TestSendWRP(t *testing.T) { client.httpClient = m } - err = client.SendWRP(ctx, &tc.response, &tc.request) + response := tc.response + request := tc.request + err = client.SendWRP(ctx, &response, &request) if tc.useMockHTTPClient { m.AssertExpectations(t) } diff --git a/wrphttp/headers.go b/wrphttp/headers.go index fa8f45c..151d6b4 100644 --- a/wrphttp/headers.go +++ b/wrphttp/headers.go @@ -31,7 +31,7 @@ import ( // Constant HTTP header strings representing WRP fields const ( MessageTypeHeader = "X-Xmidt-Message-Type" - TransactionUuidHeader = "X-Xmidt-Transaction-Uuid" + TransactionUuidHeader = "X-Xmidt-Transaction-Uuid" // nolint:gosec StatusHeader = "X-Xmidt-Status" RequestDeliveryResponseHeader = "X-Xmidt-Request-Delivery-Response" IncludeSpansHeader = "X-Xmidt-Include-Spans" diff --git a/wrphttp/headers_test.go b/wrphttp/headers_test.go index d74c737..228732b 100644 --- a/wrphttp/headers_test.go +++ b/wrphttp/headers_test.go @@ -400,7 +400,8 @@ func TestAddMessageHeaders(t *testing.T) { expected := record.expected actual := make(http.Header) - AddMessageHeaders(actual, &record.message) + message := record.message + AddMessageHeaders(actual, &message) for _, header := range regularHeaders { assert.Equal(expected[header], actual[header])