0
Fork 0
mirror of https://github.com/caddyserver/caddy.git synced 2024-12-23 22:27:38 -05:00

gzip: Fix tests

This commit is contained in:
Matthew Holt 2015-07-01 19:05:31 -06:00
parent abf22909f1
commit 32ef35b952
2 changed files with 2 additions and 2 deletions

View file

@ -108,7 +108,7 @@ func TestMIMEFilter(t *testing.T) {
}
for i, m := range mimes {
r := urlRequest("file" + m)
r.Header.Set("Content-Type", m)
r.Header.Set("Accept", m)
if !filter.ShouldCompress(r) {
t.Errorf("Test %v: Should be valid filter", i)
}

View file

@ -89,7 +89,7 @@ func TestGzipHandler(t *testing.T) {
if err != nil {
t.Error(err)
}
r.Header.Set("Content-Type", m)
r.Header.Set("Accept", m)
r.Header.Set("Accept-Encoding", "gzip")
_, err = gz.ServeHTTP(w, r)
if err != nil {