xapi-binance 0.0.1

Binance API client
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
use crate::make_test_spot_pub;
use xapi_binance::data::order_book::BnGetOrderBookParams;

#[tokio::test]
async fn test_call_failure() -> anyhow::Result<()> {
    let client = make_test_spot_pub();

    let result = client
        .get_order_book_ws(&BnGetOrderBookParams::builder().symbol("INVALID").build())
        .await;

    assert!(result.is_err());

    Ok(())
}