0
Fork 0
mirror of https://github.com/ninenines/cowboy.git synced 2025-07-14 12:20:24 +00:00

Queue HTTP/2 trailers when there's still data in the buffer

This commit is contained in:
Loïc Hoguin 2017-11-20 15:46:23 +01:00
parent 9969684035
commit 92672b49af
No known key found for this signature in database
GPG key ID: 8A9DF795F6FED764
3 changed files with 33 additions and 6 deletions

View file

@ -854,6 +854,14 @@ stream_trailers(Config) ->
{_, <<"grpc-status">>} = lists:keyfind(<<"trailer">>, 1, RespHeaders),
ok.
stream_trailers_large(Config) ->
doc("Stream large body followed by trailer headers."),
{200, RespHeaders, <<0:800000>>, [
{<<"grpc-status">>, <<"0">>}
]} = do_trailers("/resp/stream_trailers/large", Config),
{_, <<"grpc-status">>} = lists:keyfind(<<"trailer">>, 1, RespHeaders),
ok.
stream_trailers_no_te(Config) ->
doc("Stream body followed by trailer headers without a te header in the request."),
ConnPid = gun_open(Config),