Test JIT channels: check that lnpay success is true.
What changed, and why it matters
This commit only adds a check in a test script to verify that a Lightning payment succeeds. It is a test-only change and does not modify any production wallet or Lightning code. The commit message says the test has been failing since an earlier commit, but it does not describe any security problem.
No security action needed. Treat as normal test maintenance.
Security signals we found
No security-relevant code change
Test-only assertion added
No mention of vulnerability, exploit, or security fix in commit message
Evidence from the diff
The diff updates tests/regtest/regtest.sh for the ‘just_in_time’ regtest scenario. It captures the JSON result of $carol lnpay $invoice, extracts the ‘success’ field, and fails the test if it is not ‘true’. This is purely an assertion improvement in a shell-based functional test; no application logic is changed.
Changed components
tests/regtest/regtest.shInspect captured patch +5 / −1
diff --git a/tests/regtest/regtest.sh b/tests/regtest/regtest.sh
index cafe70f..e51af80 100755
--- a/tests/regtest/regtest.sh
+++ b/tests/regtest/regtest.sh
@@ -779,7 +779,11 @@ if [[ $1 == "just_in_time" ]]; then
echo "carol pays alice"
# note: set amount to 0.001 to test failure: 'payment too low'
invoice=$($alice add_request 0.01 --lightning --memo "invoice" | jq -r ".lightning_invoice")
- $carol lnpay $invoice
+ success=$($carol lnpay $invoice| jq '.success')
+ if [[ $success != "true" ]]; then
+ echo "JIT payment failed"
+ exit 1
+ fi
fi
if [[ $1 == "unixsockets" ]]; then
Why this scored 14/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.