diff options
| author | jakka <jakka@jakka.su> | 2025-10-17 17:08:43 +0300 |
|---|---|---|
| committer | jakka <jakka@jakka.su> | 2025-10-17 17:08:43 +0300 |
| commit | 27b33c13ba8cc7c4980abde2cf4a4331396376df (patch) | |
| tree | ad6ca5c1a1a45d399e27ecc9848b48d685faed46 /src/async_lib.rs | |
| parent | 38ea76f490a94b5734d4b39ca0c0be2e6ab6f90a (diff) | |
various fixes
reorganized project structure so client tests are not in the libraries
changed some types on functions for better use
Diffstat (limited to 'src/async_lib.rs')
| -rw-r--r-- | src/async_lib.rs | 30 |
1 files changed, 0 insertions, 30 deletions
diff --git a/src/async_lib.rs b/src/async_lib.rs index 55f23c2..cc0e113 100644 --- a/src/async_lib.rs +++ b/src/async_lib.rs @@ -33,33 +33,3 @@ impl From<reqwest::Error> for HydrusError { HydrusError::NetworkError(value) } } - -#[cfg(test)] -mod tests { - use crate::async_lib::{client::*, traits::*}; - - #[tokio::test] - async fn test_service_name_info() { - let mut client: HydrusClient = HydrusClient::new("http://127.0.0.1:51251/"); - client.set_api_key("7ab7accf6cf12b2c6c30436cd8fe16361aee33679dbd90da279b5c22b33d622a"); - let _ = client.get_service_name("all my files").await.unwrap(); - } - - #[tokio::test] - async fn test_service_key_info() { - let mut client: HydrusClient = HydrusClient::new("http://127.0.0.1:51251/"); - client.set_api_key("7ab7accf6cf12b2c6c30436cd8fe16361aee33679dbd90da279b5c22b33d622a"); - let _ = client - .get_service_key("616c6c206c6f63616c206d65646961") - .await - .unwrap(); - } - - #[tokio::test] - async fn test_get_services() { - let mut client: HydrusClient = HydrusClient::new("http://127.0.0.1:51251/"); - client.set_api_key("7ab7accf6cf12b2c6c30436cd8fe16361aee33679dbd90da279b5c22b33d622a"); - let res = client.get_services().await.unwrap(); - assert!(!res.is_empty()) - } -} |
