mirror of
https://github.com/ninenines/cowboy.git
synced 2025-07-14 12:20:24 +00:00
Fix some intermittent test issues in rfc7540
This commit is contained in:
parent
7d4791b32c
commit
3ebd01805f
1 changed files with 2 additions and 2 deletions
|
@ -530,7 +530,7 @@ http_upgrade_response_half_closed(Config) ->
|
||||||
%% Try sending more data after the upgrade and get an error.
|
%% Try sending more data after the upgrade and get an error.
|
||||||
{ok, Socket} = gen_tcp:connect("localhost", config(port, Config), [binary, {active, false}]),
|
{ok, Socket} = gen_tcp:connect("localhost", config(port, Config), [binary, {active, false}]),
|
||||||
ok = gen_tcp:send(Socket, [
|
ok = gen_tcp:send(Socket, [
|
||||||
"GET / HTTP/1.1\r\n"
|
"GET /long_polling HTTP/1.1\r\n"
|
||||||
"Host: localhost\r\n"
|
"Host: localhost\r\n"
|
||||||
"Connection: Upgrade, HTTP2-Settings\r\n"
|
"Connection: Upgrade, HTTP2-Settings\r\n"
|
||||||
"Upgrade: h2c\r\n"
|
"Upgrade: h2c\r\n"
|
||||||
|
@ -1893,7 +1893,7 @@ half_closed_remote_accept_rst_stream(Config) ->
|
||||||
{<<":method">>, <<"GET">>},
|
{<<":method">>, <<"GET">>},
|
||||||
{<<":scheme">>, <<"http">>},
|
{<<":scheme">>, <<"http">>},
|
||||||
{<<":authority">>, <<"localhost">>}, %% @todo Correct port number.
|
{<<":authority">>, <<"localhost">>}, %% @todo Correct port number.
|
||||||
{<<":path">>, <<"/">>}
|
{<<":path">>, <<"/long_polling">>}
|
||||||
]),
|
]),
|
||||||
ok = gen_tcp:send(Socket, cow_http2:headers(1, fin, HeadersBlock)),
|
ok = gen_tcp:send(Socket, cow_http2:headers(1, fin, HeadersBlock)),
|
||||||
%% Send an RST_STREAM frame on that now half-closed (remote) stream.
|
%% Send an RST_STREAM frame on that now half-closed (remote) stream.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue