fix formatting

This commit is contained in:
ibraheemdev 2021-03-08 11:49:40 -05:00
parent f1a59abea7
commit 9b5e1e283d
1 changed files with 12 additions and 4 deletions

View File

@ -254,8 +254,12 @@ where
{ {
let body = read_body(res).await; let body = read_body(res).await;
serde_json::from_slice(&body) serde_json::from_slice(&body).unwrap_or_else(|e| {
.unwrap_or_else(|e| panic!("read_response_json failed during deserialization of body: {:?}, {}", body, e)) panic!(
"read_response_json failed during deserialization of body: {:?}, {}",
body, e
)
})
} }
pub async fn load_stream<S>(mut stream: S) -> Result<Bytes, Error> pub async fn load_stream<S>(mut stream: S) -> Result<Bytes, Error>
@ -311,8 +315,12 @@ where
{ {
let body = read_response(app, req).await; let body = read_response(app, req).await;
serde_json::from_slice(&body) serde_json::from_slice(&body).unwrap_or_else(|_| {
.unwrap_or_else(|_| panic!("read_response_json failed during deserialization of body: {:?}", body)) panic!(
"read_response_json failed during deserialization of body: {:?}",
body
)
})
} }
/// Test `Request` builder. /// Test `Request` builder.