Skip to content

Commit 10ad8e2

Browse files
committed
f check to 7 confs
1 parent c2ce0ac commit 10ad8e2

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

lightning-invoice/src/utils.rs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -859,7 +859,15 @@ mod test {
859859
match_invoice_routes(Some(5000), &nodes[1], scid_aliases.clone());
860860
// This also applies even if the amount is more than the payment amount, to ensure users
861861
// dont screw up their privacy.
862-
match_invoice_routes(Some(50_000_000), &nodes[1], scid_aliases);
862+
match_invoice_routes(Some(50_000_000), &nodes[1], scid_aliases.clone());
863+
864+
// The same remains true until the channel has 7 confirmations, at which point we include
865+
// no hints.
866+
connect_blocks(&nodes[1], 5);
867+
match_invoice_routes(Some(5000), &nodes[1], scid_aliases.clone());
868+
connect_blocks(&nodes[1], 1);
869+
get_event_msg!(nodes[1], MessageSendEvent::SendAnnouncementSignatures, nodes[0].node.get_our_node_id());
870+
match_invoice_routes(Some(5000), &nodes[1], HashSet::new());
863871
}
864872

865873
#[test]

0 commit comments

Comments
 (0)