fix Body to return errors when there is recv error

This commit is contained in:
Sean McArthur
2017-09-11 14:46:46 -07:00
parent ed472f109c
commit e2cda1860b
3 changed files with 17 additions and 32 deletions

View File

@@ -225,17 +225,8 @@ fn recv_data_overflows_connection_window() {
.and_then(|resp| {
assert_eq!(resp.status(), StatusCode::OK);
let body = resp.into_parts().1;
// FIXME: body stream should error also
body.concat2().unwrap()
/* FIXME: body stream should error also
.then(|res| {
let err = res.unwrap_err();
assert_eq!(
err.to_string(),
"protocol error: flow-control protocol violated"
);
Ok::<(), ()>(())
})
*/
});
// client should see a flow control error