Skip to content

Commit f4bb7c9

Browse files
committed
f more comment, correct check
1 parent c35584c commit f4bb7c9

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

lightning/src/ln/functional_tests.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4744,7 +4744,7 @@ fn test_duplicate_payment_hash_one_failure_one_success() {
47444744
if node_txn.len() > 2 {
47454745
check_spends!(node_txn[1], commitment_txn[0]);
47464746
assert_eq!(node_txn[1].input.len(), 1);
4747-
assert_eq!(node_txn[2].output.len(), 1);
4747+
assert_eq!(node_txn[1].output.len(), 1);
47484748
assert_eq!(node_txn[0].input[0].previous_output, node_txn[1].input[0].previous_output);
47494749

47504750
check_spends!(node_txn[2], commitment_txn[0]);
@@ -4760,7 +4760,8 @@ fn test_duplicate_payment_hash_one_failure_one_success() {
47604760

47614761
assert_eq!(node_txn[0].input[0].witness.last().unwrap().len(), ACCEPTED_HTLC_SCRIPT_WEIGHT);
47624762
assert_eq!(node_txn[1].input[0].witness.last().unwrap().len(), ACCEPTED_HTLC_SCRIPT_WEIGHT);
4763-
// Assign htlc_timeout_tx to the second HTLC (with value ~800 sats).
4763+
// Assign htlc_timeout_tx to the forwarded HTLC (with value ~800 sats). The received HTLC
4764+
// (with value 900 sats) will be claimed in the below `claim_funds` call.
47644765
if node_txn.len() > 2 {
47654766
assert_eq!(node_txn[2].input[0].witness.last().unwrap().len(), ACCEPTED_HTLC_SCRIPT_WEIGHT);
47664767
htlc_timeout_tx = if node_txn[2].output[0].value < 900 { node_txn[2].clone() } else { node_txn[0].clone() };

0 commit comments

Comments
 (0)