@@ -1937,8 +1937,7 @@ mod tests {
1937
1937
PaymentParameters , Route , RouteHint , RouteHintHop , RouteHop , RoutingFees ,
1938
1938
DEFAULT_MAX_TOTAL_CLTV_EXPIRY_DELTA , MAX_PATH_LENGTH_ESTIMATE } ;
1939
1939
use routing:: scoring:: { ChannelUsage , Score , ProbabilisticScorer , ProbabilisticScoringParameters } ;
1940
- use routing:: test_utils:: { add_channel, add_or_update_node, build_graph, build_line_graph, id_to_feature_flags, get_nodes, update_channel} ;
1941
- use chain:: transaction:: OutPoint ;
1940
+ use routing:: test_utils:: { add_channel, add_or_update_node, build_graph, build_line_graph, get_channel_details, id_to_feature_flags, get_nodes, update_channel} ;
1942
1941
use chain:: keysinterface:: KeysInterface ;
1943
1942
use ln:: features:: { ChannelFeatures , InitFeatures , NodeFeatures } ;
1944
1943
use ln:: msgs:: { ErrorAction , LightningError , UnsignedChannelUpdate , MAX_VALUE_MSAT } ;
@@ -1948,7 +1947,6 @@ mod tests {
1948
1947
#[ cfg( c_bindings) ]
1949
1948
use util:: ser:: { Writeable , Writer } ;
1950
1949
1951
- use bitcoin:: hashes:: Hash ;
1952
1950
use bitcoin:: network:: constants:: Network ;
1953
1951
use bitcoin:: blockdata:: constants:: genesis_block;
1954
1952
use bitcoin:: blockdata:: script:: Builder ;
@@ -1965,40 +1963,6 @@ mod tests {
1965
1963
1966
1964
use core:: convert:: TryInto ;
1967
1965
1968
- fn get_channel_details ( short_channel_id : Option < u64 > , node_id : PublicKey ,
1969
- features : InitFeatures , outbound_capacity_msat : u64 ) -> channelmanager:: ChannelDetails {
1970
- channelmanager:: ChannelDetails {
1971
- channel_id : [ 0 ; 32 ] ,
1972
- counterparty : channelmanager:: ChannelCounterparty {
1973
- features,
1974
- node_id,
1975
- unspendable_punishment_reserve : 0 ,
1976
- forwarding_info : None ,
1977
- outbound_htlc_minimum_msat : None ,
1978
- outbound_htlc_maximum_msat : None ,
1979
- } ,
1980
- funding_txo : Some ( OutPoint { txid : bitcoin:: Txid :: from_slice ( & [ 0 ; 32 ] ) . unwrap ( ) , index : 0 } ) ,
1981
- channel_type : None ,
1982
- short_channel_id,
1983
- outbound_scid_alias : None ,
1984
- inbound_scid_alias : None ,
1985
- channel_value_satoshis : 0 ,
1986
- user_channel_id : 0 ,
1987
- balance_msat : 0 ,
1988
- outbound_capacity_msat,
1989
- next_outbound_htlc_limit_msat : outbound_capacity_msat,
1990
- inbound_capacity_msat : 42 ,
1991
- unspendable_punishment_reserve : None ,
1992
- confirmations_required : None ,
1993
- force_close_spend_delay : None ,
1994
- is_outbound : true , is_channel_ready : true ,
1995
- is_usable : true , is_public : true ,
1996
- inbound_htlc_minimum_msat : None ,
1997
- inbound_htlc_maximum_msat : None ,
1998
- config : None ,
1999
- }
2000
- }
2001
-
2002
1966
#[ test]
2003
1967
fn simple_route_test ( ) {
2004
1968
let ( secp_ctx, network_graph, _, _, logger) = build_graph ( ) ;
0 commit comments