ruddr 1.1.1

A lightweight Ruddr SDK Rust crate
Documentation
use super::*;

#[tokio::test]
async fn test_cost() {
    let client = client::Client::new(Some("abcdefghi123456789"))
        .expect("client with token could not be constructed");
    assert_eq!(
        cost(
            &client,
            types::UUID::try_from("b3a100b0-8e71-4f39-9d96-32f11838aa8c")
                .expect("uuid conversion failed"),
        )
        .await
        .unwrap_err()
        .to_string(),
        "client read response failed",
        "cost retrieval did not fail on auth",
    )
}

#[tokio::test]
async fn test_costs() {
    let client = client::Client::new(Some("abcdefghi123456789"))
        .expect("client with token could not be constructed");
    assert_eq!(
        costs(
            &client,
            Some(
                types::UUID::try_from("ec5543de-3b0f-47a0-b8ef-a6e18dc4b885")
                    .expect("invalid UUID")
            ),
        )
        .await
        .unwrap_err()
        .to_string(),
        "client read response failed",
        "costs retrieval did not fail on auth",
    )
}