Skip to content

Commit f7584a6

Browse files
committed
f update for new fn names
1 parent 1d16ae4 commit f7584a6

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

lightning/src/ln/functional_tests.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8139,7 +8139,7 @@ fn test_preimage_storage() {
81398139
create_announced_chan_between_nodes(&nodes, 0, 1, InitFeatures::known(), InitFeatures::known()).0.contents.short_channel_id;
81408140

81418141
{
8142-
let (payment_hash, payment_secret) = nodes[1].node.get_payment_secret_preimage(Some(100_000), 1008, 42);
8142+
let (payment_hash, payment_secret) = nodes[1].node.create_inbound_payment(Some(100_000), 1008, 42);
81438143

81448144
let logger = test_utils::TestLogger::new();
81458145
let net_graph_msg_handler = &nodes[0].net_graph_msg_handler;
@@ -8175,22 +8175,22 @@ fn test_secret_timeout() {
81758175

81768176
create_announced_chan_between_nodes(&nodes, 0, 1, InitFeatures::known(), InitFeatures::known()).0.contents.short_channel_id;
81778177

8178-
let (payment_hash, payment_secret_1) = nodes[1].node.get_payment_secret_preimage(Some(100_000), 2, 0);
8178+
let (payment_hash, payment_secret_1) = nodes[1].node.create_inbound_payment(Some(100_000), 2, 0);
81798179

81808180
// We should fail to register the same payment hash twice, at least until we've connected two
81818181
// blocks.
8182-
if let Err(APIError::APIMisuseError { err }) = nodes[1].node.get_payment_secret(payment_hash, Some(100_000), 2, 0) {
8182+
if let Err(APIError::APIMisuseError { err }) = nodes[1].node.create_inbound_payment_for_hash(payment_hash, Some(100_000), 2, 0) {
81838183
assert_eq!(err, "Duplicate payment hash");
81848184
} else { panic!(); }
81858185
connect_blocks(&nodes[1], 1);
8186-
if let Err(APIError::APIMisuseError { err }) = nodes[1].node.get_payment_secret(payment_hash, Some(100_000), 2, 0) {
8186+
if let Err(APIError::APIMisuseError { err }) = nodes[1].node.create_inbound_payment_for_hash(payment_hash, Some(100_000), 2, 0) {
81878187
assert_eq!(err, "Duplicate payment hash");
81888188
} else { panic!(); }
81898189

81908190
// If we then connect the second block, we should be able to register the same payment hash
81918191
// again with a different user_payment_id (this time getting a new payment secret).
81928192
connect_blocks(&nodes[1], 1);
8193-
let our_payment_secret = nodes[1].node.get_payment_secret(payment_hash, Some(100_000), 2, 42).unwrap();
8193+
let our_payment_secret = nodes[1].node.create_inbound_payment_for_hash(payment_hash, Some(100_000), 2, 42).unwrap();
81948194
assert_ne!(payment_secret_1, our_payment_secret);
81958195

81968196
{
@@ -8232,7 +8232,7 @@ fn test_bad_secret_hash() {
82328232

82338233
let random_payment_hash = PaymentHash([42; 32]);
82348234
let random_payment_secret = PaymentSecret([43; 32]);
8235-
let (our_payment_hash, our_payment_secret) = nodes[1].node.get_payment_secret_preimage(Some(100_000), 2, 0);
8235+
let (our_payment_hash, our_payment_secret) = nodes[1].node.create_inbound_payment(Some(100_000), 2, 0);
82368236

82378237
let logger = test_utils::TestLogger::new();
82388238
let net_graph_msg_handler = &nodes[0].net_graph_msg_handler;

0 commit comments

Comments
 (0)