pub const GET_COINBASE_TX_SUM_RESPONSE: &str = r#"{
"id": "0",
"jsonrpc": "2.0",
"result": {
"credits": 0,
"emission_amount": 9387854817320,
"emission_amount_top64": 0,
"fee_amount": 83981380000,
"fee_amount_top64": 0,
"status": "OK",
"top_hash": "",
"untrusted": false,
"wide_emission_amount": "0x889c7c06828",
"wide_fee_amount": "0x138dae29a0"
}
}"#;
Expand description
Documentation, request.
use cuprate_test_utils::rpc::data::json::*;
use serde_json::{to_value, Value};
let value = serde_json::from_str::<Value>(&GET_COINBASE_TX_SUM_RESPONSE).unwrap();
let Value::Object(map) = value else {
panic!();
};
assert_eq!(map.get("jsonrpc").unwrap(), "2.0");
map.get("id").unwrap();
if map.get("method").is_some() {
return;
}
if map.get("result").is_none() {
map.get("error").unwrap();
}