diff options
author | Alex Auvolat <alex@adnab.me> | 2023-08-28 12:32:57 +0200 |
---|---|---|
committer | Alex Auvolat <alex@adnab.me> | 2023-08-28 12:32:57 +0200 |
commit | e66c78d6eaeb01b64911013b3a36d798c561acb8 (patch) | |
tree | 1c142acc9b25ead49e14af35660497964463bf43 /src/garage/tests/k2v/mod.rs | |
parent | 51011e68b16efc2232606bee47fcdc9e8a11068e (diff) | |
download | garage-e66c78d6eaeb01b64911013b3a36d798c561acb8.tar.gz garage-e66c78d6eaeb01b64911013b3a36d798c561acb8.zip |
integration test: move json_body to root of crate
Diffstat (limited to 'src/garage/tests/k2v/mod.rs')
-rw-r--r-- | src/garage/tests/k2v/mod.rs | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/src/garage/tests/k2v/mod.rs b/src/garage/tests/k2v/mod.rs index a009460e..241e3dc2 100644 --- a/src/garage/tests/k2v/mod.rs +++ b/src/garage/tests/k2v/mod.rs @@ -3,16 +3,3 @@ pub mod errorcodes; pub mod item; pub mod poll; pub mod simple; - -use hyper::{Body, Response}; - -pub async fn json_body(res: Response<Body>) -> serde_json::Value { - let res_body: serde_json::Value = serde_json::from_slice( - &hyper::body::to_bytes(res.into_body()) - .await - .unwrap() - .to_vec()[..], - ) - .unwrap(); - res_body -} |