tests: Allow specifying http version in curl

Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
This commit is contained in:
Marek Siarkowicz 2023-03-14 15:43:59 +01:00
parent cee9d4c0f1
commit 063d3ceed6

View File

@ -134,7 +134,8 @@ type cURLReq struct {
metricsURLScheme string
ciphers string
ciphers string
httpVersion string
}
// cURLPrefixArgsCluster builds the beginning of a curl command for a given key
@ -152,6 +153,9 @@ func cURLPrefixArgs(clientURL string, connType clientConnType, CN bool, method s
var (
cmdArgs = []string{"curl"}
)
if req.httpVersion != "" {
cmdArgs = append(cmdArgs, "--http"+req.httpVersion)
}
if req.metricsURLScheme != "https" {
if req.isTLS {
if connType != clientTLSAndNonTLS {