From: Jeffrey Czyz Date: Tue, 19 Mar 2024 21:07:20 +0000 (-0500) Subject: pub(crate) visibility for routing/test_utils.rs X-Git-Tag: v0.0.123-beta~34^2~2 X-Git-Url: http://git.bitcoin.ninja/?a=commitdiff_plain;h=3d2a0c2832ca71e6d75d335b6e3d7490f8f220b8;p=rust-lightning pub(crate) visibility for routing/test_utils.rs Give pub(crate) visibility to some routing test utilities to facilitate testing DefaultMessageRouter in functional tests. --- diff --git a/lightning/src/routing/mod.rs b/lightning/src/routing/mod.rs index 7fff85634..9e6d8e2af 100644 --- a/lightning/src/routing/mod.rs +++ b/lightning/src/routing/mod.rs @@ -14,4 +14,4 @@ pub mod gossip; pub mod router; pub mod scoring; #[cfg(test)] -mod test_utils; +pub(crate) mod test_utils; diff --git a/lightning/src/routing/test_utils.rs b/lightning/src/routing/test_utils.rs index 00c552850..9f03b4451 100644 --- a/lightning/src/routing/test_utils.rs +++ b/lightning/src/routing/test_utils.rs @@ -27,7 +27,7 @@ use crate::sync::{self, Arc}; use crate::routing::gossip::NodeId; // Using the same keys for LN and BTC ids -pub(super) fn add_channel( +pub(crate) fn add_channel( gossip_sync: &P2PGossipSync>>, Arc, Arc>, secp_ctx: &Secp256k1, node_1_privkey: &SecretKey, node_2_privkey: &SecretKey, features: ChannelFeatures, short_channel_id: u64 ) { @@ -59,7 +59,7 @@ pub(super) fn add_channel( }; } -pub(super) fn add_or_update_node( +pub(crate) fn add_or_update_node( gossip_sync: &P2PGossipSync>>, Arc, Arc>, secp_ctx: &Secp256k1, node_privkey: &SecretKey, features: NodeFeatures, timestamp: u32 ) { @@ -86,7 +86,7 @@ pub(super) fn add_or_update_node( }; } -pub(super) fn update_channel( +pub(crate) fn update_channel( gossip_sync: &P2PGossipSync>>, Arc, Arc>, secp_ctx: &Secp256k1, node_privkey: &SecretKey, update: UnsignedChannelUpdate ) {