From c48be47db91fa4f67c646a287e9d2aeb55672fa1 Mon Sep 17 00:00:00 2001 From: Alex Ellis Date: Wed, 5 Jun 2019 12:58:25 +0100 Subject: [PATCH] Copy response headers back to client Headers such as Realm / etc are important for auth proxies, so this change and unit test make sure they get copied back to the client. Signed-off-by: Alex Ellis --- auth/basic-auth/main_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/auth/basic-auth/main_test.go b/auth/basic-auth/main_test.go index b1241c52..3938a6e6 100644 --- a/auth/basic-auth/main_test.go +++ b/auth/basic-auth/main_test.go @@ -6,7 +6,7 @@ import ( "testing" ) -func Test_makeLogger(t *testing.T) { +func Test_makeLogger_CopiesResponseHeaders(t *testing.T) { handler := http.HandlerFunc(makeLogger(http.HandlerFunc( func(w http.ResponseWriter, r *http.Request) { w.Header().Set("X-Unit-Test", "true")