Skip to content

Commit e395c19

Browse files
committed
f update for new fn names
1 parent 5abd7e1 commit e395c19

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
@@ -8137,7 +8137,7 @@ fn test_preimage_storage() {
81378137
create_announced_chan_between_nodes(&nodes, 0, 1, InitFeatures::known(), InitFeatures::known()).0.contents.short_channel_id;
81388138

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

81428142
let logger = test_utils::TestLogger::new();
81438143
let net_graph_msg_handler = &nodes[0].net_graph_msg_handler;
@@ -8173,22 +8173,22 @@ fn test_secret_timeout() {
81738173

81748174
create_announced_chan_between_nodes(&nodes, 0, 1, InitFeatures::known(), InitFeatures::known()).0.contents.short_channel_id;
81758175

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

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

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

81948194
{
@@ -8230,7 +8230,7 @@ fn test_bad_secret_hash() {
82308230

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

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

0 commit comments

Comments
 (0)