]> git.ipfire.org Git - thirdparty/git.git/commitdiff
t5559: make SSL/TLS the default
authorJeff King <peff@peff.net>
Thu, 23 Feb 2023 11:08:41 +0000 (06:08 -0500)
committerJunio C Hamano <gitster@pobox.com>
Thu, 23 Feb 2023 21:01:18 +0000 (13:01 -0800)
The point of t5559 is run the regular t5551 tests with HTTP/2. But it
does so with the "h2c" protocol, which uses cleartext upgrades from
HTTP/1.1 to HTTP/2 (rather than learning about HTTP/2 support during the
TLS negotiation).

This has a few problems:

 - it's not very indicative of the real world. In practice, most servers
   that support HTTP/2 will also support TLS.

 - support for upgrading does not seem as robust. In particular, we've
   run into bugs in some versions of Apache's mod_http2 that trigger
   only with the upgrade mode. See:

     https://lore.kernel.org/git/Y8ztIqYgVCPILJlO@coredump.intra.peff.net/

So the upside is that this change makes our HTTP/2 tests more robust and
more realistic. The downside is that if we can't set up SSL for any
reason, we'll skip the tests (even though you _might_ have been able to
run the HTTP/2 tests the old way). We could probably have a conditional
fallback, but it would be complicated for little gain, and it's not even
clear it would help (i.e., would any test environment even have HTTP/2
but not SSL support?).

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t5559-http-fetch-smart-http2.sh

index 9eece71c2c2c28f00630e62e8a7a6495d23c3219..54aa9d3bffa1a7b7a04f3cc435556b13a14cf8e1 100755 (executable)
@@ -1,4 +1,5 @@
 #!/bin/sh
 
 HTTP_PROTO=HTTP/2
+LIB_HTTPD_SSL=1
 . ./t5551-http-fetch-smart.sh