Collected json result test passes

This commit is contained in:
Dominik Werder
2021-06-09 20:03:58 +02:00
parent 1df36f3aeb
commit 28b4bb3e04
4 changed files with 252 additions and 78 deletions

View File

@@ -58,7 +58,11 @@ async fn get_binned_json_0_inner2(
}
let res = hyper::body::to_bytes(res.into_body()).await?;
let res = String::from_utf8(res.to_vec())?;
info!("result from endpoint: [[[\n{}\n]]]", res);
let res: serde_json::Value = serde_json::from_str(res.as_str())?;
info!(
"result from endpoint: --------------\n{}\n--------------",
serde_json::to_string_pretty(&res)?
);
let t2 = chrono::Utc::now();
let ms = t2.signed_duration_since(t1).num_milliseconds() as u64;
info!("get_binned_json_0 DONE time {} ms", ms);