Merge branch 'ld/git-p4-updates'
[gitweb.git] / t / t5551-http-fetch-smart.sh
index f5721b4a59ea4a3333cc0e74d8ab9ad2f182dd5b..913089b14452976144878415c05a9a2c743d22bf 100755 (executable)
@@ -26,14 +26,14 @@ setup_askpass_helper
 cat >exp <<EOF
 > GET /smart/repo.git/info/refs?service=git-upload-pack HTTP/1.1
 > Accept: */*
-> Accept-Encoding: gzip
+> Accept-Encoding: ENCODINGS
 > Pragma: no-cache
 < HTTP/1.1 200 OK
 < Pragma: no-cache
 < Cache-Control: no-cache, max-age=0, must-revalidate
 < Content-Type: application/x-git-upload-pack-advertisement
 > POST /smart/repo.git/git-upload-pack HTTP/1.1
-> Accept-Encoding: gzip
+> Accept-Encoding: ENCODINGS
 > Content-Type: application/x-git-upload-pack-request
 > Accept: application/x-git-upload-pack-result
 > Content-Length: xxx
@@ -79,8 +79,13 @@ test_expect_success 'clone http repository' '
                /^< Date: /d
                /^< Content-Length: /d
                /^< Transfer-Encoding: /d
-       " >act &&
-       test_cmp exp act
+       " >actual &&
+       sed -e "s/^> Accept-Encoding: .*/> Accept-Encoding: ENCODINGS/" \
+                       actual >actual.smudged &&
+       test_cmp exp actual.smudged &&
+
+       grep "Accept-Encoding:.*gzip" actual >actual.gzip &&
+       test_line_count = 2 actual.gzip
 '
 
 test_expect_success 'fetch changes via http' '