X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=lightning%2Fsrc%2Fln%2Fpayment_tests.rs;h=412e7f774f92c24e9ae3ccb85c8c356f91f8e1e4;hb=1016e1f605ff03ed14ed875e7cd4f567ae15c96a;hp=6748f49b5bde99113dc8fda06f1cd5290af49801;hpb=dddb2e28c1e2586346d94775d5bb63414c6a73bb;p=rust-lightning diff --git a/lightning/src/ln/payment_tests.rs b/lightning/src/ln/payment_tests.rs index 6748f49b..412e7f77 100644 --- a/lightning/src/ln/payment_tests.rs +++ b/lightning/src/ln/payment_tests.rs @@ -1087,7 +1087,8 @@ fn claimed_send_payment_idempotent() { // Further, if we try to send a spontaneous payment with the same payment_id it should // also be rejected. - let send_result = nodes[0].node.send_spontaneous_payment(&route, None, payment_id); + let send_result = nodes[0].node.send_spontaneous_payment( + &route, None, RecipientOnionFields::spontaneous_empty(), payment_id); match send_result { Err(PaymentSendFailure::DuplicatePayment) => {}, _ => panic!("Unexpected send result: {:?}", send_result), @@ -1161,7 +1162,8 @@ fn abandoned_send_payment_idempotent() { // Further, if we try to send a spontaneous payment with the same payment_id it should // also be rejected. - let send_result = nodes[0].node.send_spontaneous_payment(&route, None, payment_id); + let send_result = nodes[0].node.send_spontaneous_payment( + &route, None, RecipientOnionFields::spontaneous_empty(), payment_id); match send_result { Err(PaymentSendFailure::DuplicatePayment) => {}, _ => panic!("Unexpected send result: {:?}", send_result), @@ -1671,7 +1673,9 @@ fn do_automatic_retries(test: AutoRetry) { pass_along_path(&nodes[0], &[&nodes[1], &nodes[2]], amt_msat, payment_hash, Some(payment_secret), msg_events.pop().unwrap(), true, None); claim_payment_along_route(&nodes[0], &[&[&nodes[1], &nodes[2]]], false, payment_preimage); } else if test == AutoRetry::Spontaneous { - nodes[0].node.send_spontaneous_payment_with_retry(Some(payment_preimage), PaymentId(payment_hash.0), route_params, Retry::Attempts(1)).unwrap(); + nodes[0].node.send_spontaneous_payment_with_retry(Some(payment_preimage), + RecipientOnionFields::spontaneous_empty(), PaymentId(payment_hash.0), route_params, + Retry::Attempts(1)).unwrap(); pass_failed_attempt_with_retry_along_path!(channel_id_2, true); // Open a new channel with liquidity on the second hop so we can find a route for the retry