mirror of
https://github.com/ninenines/cowboy.git
synced 2025-07-14 12:20:24 +00:00
Fix tests for OTP-25+
This commit is contained in:
parent
30ee75cea1
commit
b9d4e05be0
4 changed files with 62 additions and 32 deletions
|
@ -126,7 +126,7 @@ do_proxy_header_https(Config, ProxyInfo) ->
|
|||
{ok, Socket0} = gen_tcp:connect("localhost", config(port, Config),
|
||||
[binary, {active, false}, {packet, raw}]),
|
||||
ok = gen_tcp:send(Socket0, ranch_proxy_header:header(ProxyInfo)),
|
||||
{ok, Socket} = ssl:connect(Socket0, [], 1000),
|
||||
{ok, Socket} = ssl:connect(Socket0, [{versions, ['tlsv1.2']}], 1000),
|
||||
do_proxy_header_http_common({raw_client, Socket, ssl}, ProxyInfo).
|
||||
|
||||
do_proxy_header_http_common(Client, ProxyInfo) ->
|
||||
|
@ -151,7 +151,8 @@ do_proxy_header_h2(Config, ProxyInfo) ->
|
|||
{ok, Socket0} = gen_tcp:connect("localhost", config(port, Config),
|
||||
[binary, {active, false}, {packet, raw}]),
|
||||
ok = gen_tcp:send(Socket0, ranch_proxy_header:header(ProxyInfo)),
|
||||
{ok, Socket} = ssl:connect(Socket0, [{alpn_advertised_protocols, [<<"h2">>]}], 1000),
|
||||
{ok, Socket} = ssl:connect(Socket0,
|
||||
[{alpn_advertised_protocols, [<<"h2">>]}, {versions, ['tlsv1.2']}], 1000),
|
||||
do_proxy_header_h2_common({raw_client, Socket, ssl}, ProxyInfo).
|
||||
|
||||
do_proxy_header_h2c(Config, ProxyInfo) ->
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue