Skip to content

Commit 4b941ea

Browse files
committed
f docs
1 parent bd428bf commit 4b941ea

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

lightning/src/ln/functional_test_utils.rs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1394,6 +1394,7 @@ impl SendEvent {
13941394
}
13951395

13961396
#[macro_export]
1397+
/// Don't use this, use the identically-named function instead.
13971398
macro_rules! expect_pending_htlcs_forwardable_conditions {
13981399
($node: expr, $expected_failures: expr) => {
13991400
$crate::ln::functional_test_utils::expect_pending_htlcs_forwardable_conditions(&$node, &$expected_failures);
@@ -1415,6 +1416,9 @@ macro_rules! expect_htlc_handling_failed_destinations {
14151416
}}
14161417
}
14171418

1419+
/// Checks that an [`Event::PendingHTLCsForwardable`] is available on the given node and, if there
1420+
/// are any [`Event::HTLCHandlingFailed`] events their [`HTLCDestination`] is included in the
1421+
/// `expected_failures` set.
14181422
pub fn expect_pending_htlcs_forwardable_conditions(node: &Node, expected_failures: &[HTLCDestination]) {
14191423
let events = node.node.get_and_clear_pending_events();
14201424
match events[0] {
@@ -1432,6 +1436,9 @@ pub fn expect_pending_htlcs_forwardable_conditions(node: &Node, expected_failure
14321436

14331437
#[macro_export]
14341438
/// Clears (and ignores) a PendingHTLCsForwardable event
1439+
///
1440+
/// Don't use this, call [`expect_pending_htlcs_forwardable_conditions`] with an empty failure set
1441+
/// instead.
14351442
macro_rules! expect_pending_htlcs_forwardable_ignore {
14361443
($node: expr) => {
14371444
$crate::ln::functional_test_utils::expect_pending_htlcs_forwardable_conditions(&$node, &[]);
@@ -1440,6 +1447,8 @@ macro_rules! expect_pending_htlcs_forwardable_ignore {
14401447

14411448
#[macro_export]
14421449
/// Clears (and ignores) PendingHTLCsForwardable and HTLCHandlingFailed events
1450+
///
1451+
/// Don't use this, call [`expect_pending_htlcs_forwardable_conditions`] instead.
14431452
macro_rules! expect_pending_htlcs_forwardable_and_htlc_handling_failed_ignore {
14441453
($node: expr, $expected_failures: expr) => {
14451454
$crate::ln::functional_test_utils::expect_pending_htlcs_forwardable_conditions(&$node, &$expected_failures);

0 commit comments

Comments
 (0)