#[cfg(feature = "hashbrown")]
extern crate hashbrown;
- pub use alloc::{vec, vec::Vec, string::String, collections::VecDeque, boxed::Box};
+ pub use alloc::{vec, vec::Vec, string::String};
#[cfg(not(feature = "hashbrown"))]
- pub use std::collections::{HashMap, HashSet, hash_map};
+ pub use std::collections::{HashMap, hash_map};
#[cfg(feature = "hashbrown")]
pub use self::hashbrown::{HashMap, HashSet, hash_map};
use crate::prelude::*;
-/// Sync compat for std/no_std
-#[cfg(feature = "std")]
-mod sync {
- pub use ::std::sync::{Mutex, MutexGuard};
-}
-
/// Sync compat for std/no_std
#[cfg(not(feature = "std"))]
mod sync;
let _chan = create_chan_between_nodes(&nodes[0], &nodes[1]);
let route_params = RouteParameters::from_payment_params_and_value(
PaymentParameters::for_keysend(payee_pubkey, 40, false), 10_000);
- let network_graph = nodes[0].network_graph.clone();
+ let network_graph = nodes[0].network_graph;
let first_hops = nodes[0].node.list_usable_channels();
let scorer = test_utils::TestScorer::new();
let random_seed_bytes = chanmon_cfgs[1].keys_manager.get_secure_random_bytes();
let _chan = create_chan_between_nodes(&nodes[0], &nodes[1]);
let route_params = RouteParameters::from_payment_params_and_value(
PaymentParameters::for_keysend(payee_pubkey, 40, false), 10_000);
- let network_graph = nodes[0].network_graph.clone();
+ let network_graph = nodes[0].network_graph;
let first_hops = nodes[0].node.list_usable_channels();
let scorer = test_utils::TestScorer::new();
let random_seed_bytes = chanmon_cfgs[1].keys_manager.get_secure_random_bytes();
let route_params = RouteParameters::from_payment_params_and_value(
PaymentParameters::for_keysend(payee_pubkey, 40, false), 10000);
- let network_graph = nodes[0].network_graph.clone();
+ let network_graph = nodes[0].network_graph;
let channels = nodes[0].node.list_usable_channels();
let first_hops = channels.iter().collect::<Vec<_>>();
let first_hops = if public_node { None } else { Some(first_hops.as_slice()) };
create_announced_chan_between_nodes(&nodes, 0, 2);
create_announced_chan_between_nodes(&nodes, 1, 3);
create_announced_chan_between_nodes(&nodes, 2, 3);
- let network_graph = nodes[0].network_graph.clone();
+ let network_graph = nodes[0].network_graph;
let payer_pubkey = nodes[0].node.get_our_node_id();
let payee_pubkey = nodes[3].node.get_our_node_id();
create_announced_chan_between_nodes(&nodes, 1, 2);
let recv_value = 100_000;
- let (route, payment_hash, _, _) = get_route_and_payment_hash!(&nodes[0], nodes[2], recv_value);
+ let (route, _, _, _) = get_route_and_payment_hash!(&nodes[0], nodes[2], recv_value);
let res = nodes[0].node.send_probe(route.paths[0].clone()).unwrap();
fee_estimator: &fee_estimator,
router: &nodes[0].router,
chain_monitor: nodes[0].chain_monitor,
- tx_broadcaster: nodes[0].tx_broadcaster.clone(),
+ tx_broadcaster: nodes[0].tx_broadcaster,
logger: &logger,
channel_monitors: node_0_stale_monitors.iter_mut().map(|monitor| { (monitor.get_funding_txo().0, monitor) }).collect(),
}) { } else {
fee_estimator: &fee_estimator,
router: nodes[0].router,
chain_monitor: nodes[0].chain_monitor,
- tx_broadcaster: nodes[0].tx_broadcaster.clone(),
+ tx_broadcaster: nodes[0].tx_broadcaster,
logger: &logger,
channel_monitors: node_0_monitors.iter_mut().map(|monitor| { (monitor.get_funding_txo().0, monitor) }).collect(),
}).unwrap();