From: Matt Corallo <649246+TheBlueMatt@users.noreply.github.com> Date: Wed, 11 Sep 2024 22:25:41 +0000 (+0000) Subject: Merge pull request #3291 from tnull/2024-09-add-their-node-id-routing-msg-handler X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=commitdiff_plain;h=db905e8a8d620b880fb14e5e574d4d733d64cd06;p=rust-lightning Merge pull request #3291 from tnull/2024-09-add-their-node-id-routing-msg-handler Add node id to remaining `RoutingMessageHandler::handle_` methods --- db905e8a8d620b880fb14e5e574d4d733d64cd06 diff --cc lightning/src/ln/offers_tests.rs index 8e4de107a,bf7c48142..689441b81 --- a/lightning/src/ln/offers_tests.rs +++ b/lightning/src/ln/offers_tests.rs @@@ -575,12 -576,12 +576,12 @@@ fn creates_and_pays_for_offer_using_two assert_eq!(reply_path.introduction_node(), &IntroductionNode::NodeId(charlie_id)); let onion_message = alice.onion_messenger.next_onion_message_for_peer(charlie_id).unwrap(); - charlie.onion_messenger.handle_onion_message(&alice_id, &onion_message); + charlie.onion_messenger.handle_onion_message(alice_id, &onion_message); let onion_message = charlie.onion_messenger.next_onion_message_for_peer(david_id).unwrap(); - david.onion_messenger.handle_onion_message(&charlie_id, &onion_message); + david.onion_messenger.handle_onion_message(charlie_id, &onion_message); - let (invoice, _) = extract_invoice(david, &onion_message); + let (invoice, reply_path) = extract_invoice(david, &onion_message); assert_eq!(invoice.amount_msats(), 10_000_000); assert_ne!(invoice.signing_pubkey(), alice_id); assert!(!invoice.payment_paths().is_empty()); @@@ -663,12 -655,12 +664,12 @@@ fn creates_and_pays_for_refund_using_tw connect_peers(alice, charlie); let onion_message = alice.onion_messenger.next_onion_message_for_peer(charlie_id).unwrap(); - charlie.onion_messenger.handle_onion_message(&alice_id, &onion_message); + charlie.onion_messenger.handle_onion_message(alice_id, &onion_message); let onion_message = charlie.onion_messenger.next_onion_message_for_peer(david_id).unwrap(); - david.onion_messenger.handle_onion_message(&charlie_id, &onion_message); + david.onion_messenger.handle_onion_message(charlie_id, &onion_message); - let (invoice, _) = extract_invoice(david, &onion_message); + let (invoice, reply_path) = extract_invoice(david, &onion_message); assert_eq!(invoice, expected_invoice); assert_eq!(invoice.amount_msats(), 10_000_000); @@@ -735,9 -725,9 +736,9 @@@ fn creates_and_pays_for_offer_using_one assert_eq!(reply_path.introduction_node(), &IntroductionNode::NodeId(bob_id)); let onion_message = alice.onion_messenger.next_onion_message_for_peer(bob_id).unwrap(); - bob.onion_messenger.handle_onion_message(&alice_id, &onion_message); + bob.onion_messenger.handle_onion_message(alice_id, &onion_message); - let (invoice, _) = extract_invoice(bob, &onion_message); + let (invoice, reply_path) = extract_invoice(bob, &onion_message); assert_eq!(invoice.amount_msats(), 10_000_000); assert_ne!(invoice.signing_pubkey(), alice_id); assert!(!invoice.payment_paths().is_empty()); @@@ -789,9 -778,9 +790,9 @@@ fn creates_and_pays_for_refund_using_on let expected_invoice = alice.node.request_refund_payment(&refund).unwrap(); let onion_message = alice.onion_messenger.next_onion_message_for_peer(bob_id).unwrap(); - bob.onion_messenger.handle_onion_message(&alice_id, &onion_message); + bob.onion_messenger.handle_onion_message(alice_id, &onion_message); - let (invoice, _) = extract_invoice(bob, &onion_message); + let (invoice, reply_path) = extract_invoice(bob, &onion_message); assert_eq!(invoice, expected_invoice); assert_eq!(invoice.amount_msats(), 10_000_000); @@@ -1201,9 -1189,9 +1202,9 @@@ fn creates_offer_with_blinded_path_usin assert_eq!(reply_path.introduction_node(), &IntroductionNode::NodeId(alice_id)); let onion_message = alice.onion_messenger.next_onion_message_for_peer(bob_id).unwrap(); - bob.onion_messenger.handle_onion_message(&alice_id, &onion_message); + bob.onion_messenger.handle_onion_message(alice_id, &onion_message); - let (invoice, _) = extract_invoice(bob, &onion_message); + let (invoice, reply_path) = extract_invoice(bob, &onion_message); assert_ne!(invoice.signing_pubkey(), alice_id); assert!(!invoice.payment_paths().is_empty()); for path in invoice.payment_paths() {