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 <alexellis2@gmail.com>
This commit is contained in:
Alex Ellis 2019-06-05 12:58:25 +01:00
parent 95d4d50e8e
commit c48be47db9

View File

@ -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")