package gitrepo

import "testing"

func TestGzipContentEncoding(t *testing.T) {
	cases := []struct{ in, want string }{
		{"", ""},
		{"identity", ""},
		{"deflate", ""},
		{"gzip", "gzip"},
		{"GZIP", "gzip"},
		{"x-gzip", "x-gzip"},
		{"gzip, deflate", "gzip"},
		{"  gzip  ", "gzip"},
	}
	for _, tc := range cases {
		if got := gzipContentEncoding(tc.in); got != tc.want {
			t.Errorf("%q: %q, verwacht %q", tc.in, got, tc.want)
		}
	}
}
