From a2799c4505b649076800742df4fe51c9afe55ddc Mon Sep 17 00:00:00 2001 From: Gabriel Comte Date: Mon, 13 May 2024 17:40:43 +0200 Subject: [PATCH] Mock lnurlp comment --- mock/breez-sdk/src/lib.rs | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/mock/breez-sdk/src/lib.rs b/mock/breez-sdk/src/lib.rs index 6b1c5276..f24d42ba 100644 --- a/mock/breez-sdk/src/lib.rs +++ b/mock/breez-sdk/src/lib.rs @@ -177,6 +177,7 @@ impl BreezServices { destination_pubkey: parsed_invoice.payee_pubkey, bolt11: req.bolt11, lnurl_pay_domain: None, + lnurl_pay_comment: None, ln_address: None, lnurl_metadata: None, lnurl_withdraw_endpoint: None, @@ -325,6 +326,7 @@ impl BreezServices { destination_pubkey: PAYEE_PUBKEY_DUMMY.to_string(), bolt11: BOLT11_DUMMY.to_string(), lnurl_pay_domain: Some(req.data.domain.clone()), + lnurl_pay_comment: req.comment.clone(), ln_address: req.data.ln_address.clone(), lnurl_metadata: Some(req.data.metadata_str.clone()), lnurl_withdraw_endpoint: None, @@ -365,6 +367,7 @@ impl BreezServices { destination_pubkey: NODE_PUBKEY.clone(), bolt11: bolt11.clone(), lnurl_pay_domain: None, + lnurl_pay_comment: None, ln_address: None, lnurl_metadata: None, lnurl_withdraw_endpoint: Some("https://lnurl.dummy.com/lnurl-withdraw".to_string()), @@ -471,6 +474,7 @@ impl BreezServices { destination_pubkey: NODE_PUBKEY.to_string(), bolt11: invoice.to_string(), lnurl_pay_domain: None, + lnurl_pay_comment: None, ln_address: None, lnurl_metadata: None, lnurl_withdraw_endpoint: None, @@ -646,6 +650,7 @@ impl BreezServices { destination_pubkey: NODE_PUBKEY.to_string(), bolt11: swap.clone().bolt11.unwrap_or_default(), lnurl_pay_domain: None, + lnurl_pay_comment: None, ln_address: None, lnurl_metadata: None, lnurl_withdraw_endpoint: None, @@ -826,6 +831,7 @@ impl BreezServices { destination_pubkey: PAYEE_PUBKEY_DUMMY.to_string(), bolt11: BOLT11_DUMMY.to_string(), lnurl_pay_domain: None, + lnurl_pay_comment: None, ln_address: None, lnurl_metadata: None, lnurl_withdraw_endpoint: None, @@ -961,6 +967,7 @@ impl BreezServices { destination_pubkey: PAYEE_PUBKEY_DUMMY.to_string(), bolt11: swap.bolt11.clone().unwrap_or(BOLT11_DUMMY.to_string()), lnurl_pay_domain: None, + lnurl_pay_comment: None, ln_address: None, lnurl_metadata: None, lnurl_withdraw_endpoint: None, @@ -1026,6 +1033,7 @@ impl BreezServices { destination_pubkey: PAYEE_PUBKEY_DUMMY.to_string(), bolt11: BOLT11_DUMMY.to_string(), lnurl_pay_domain: None, + lnurl_pay_comment: None, ln_address, lnurl_metadata: None, lnurl_withdraw_endpoint: None, @@ -1129,6 +1137,7 @@ struct MockPayment { destination_pubkey: String, bolt11: String, lnurl_pay_domain: Option, + lnurl_pay_comment: Option, ln_address: Option, lnurl_metadata: Option, lnurl_withdraw_endpoint: Option, @@ -1159,7 +1168,7 @@ fn create_payment(p: MockPayment) -> Payment { open_channel_bolt11: None, lnurl_success_action: None, lnurl_pay_domain: p.lnurl_pay_domain, - lnurl_pay_comment: None, + lnurl_pay_comment: p.lnurl_pay_comment, ln_address: p.ln_address, lnurl_metadata: p.lnurl_metadata, lnurl_withdraw_endpoint: p.lnurl_withdraw_endpoint,