-
Notifications
You must be signed in to change notification settings - Fork 407
Make test_duplicate_payment_hash_one_failure_one_success
robust
#1984
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make test_duplicate_payment_hash_one_failure_one_success
robust
#1984
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One nit, otherwise LGTM.
CI failure seems unrelated.
LGTM after squash |
Codecov ReportBase: 90.79% // Head: 91.06% // Increases project coverage by
📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more Additional details and impacted files@@ Coverage Diff @@
## main #1984 +/- ##
==========================================
+ Coverage 90.79% 91.06% +0.27%
==========================================
Files 98 99 +1
Lines 51673 55379 +3706
Branches 51673 55379 +3706
==========================================
+ Hits 46915 50431 +3516
- Misses 4758 4948 +190
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
`test_duplicate_payment_hash_one_failure_one_success` currently fails if the "wrong" HTLC is picked to be claimed. Given the HTLCs are identical, there's no way to figure out which we should claim. The test instead relies on a magic value - the first one is the right one....unless we change our CSPRNG implementation. When we try to do so, the test randomly fails. Here we change one HTLC to a lower amount so we can figure out which transaction to broadcast to make the test robust against CSPRNG changes.
f4bb7c9
to
7dcbf2c
Compare
Squashed. |
test_duplicate_payment_hash_one_failure_one_success
currently fails if the "wrong" HTLC is picked to be claimed. Given the HTLCs are identical, there's no way to figure out which we should claim. The test instead relies on a magic value - the first one is the right one....unless we change our CSPRNG implementation. When we try to do so, the test randomly fails.Here we change one HTLC to a lower amount so we can figure out which transaction to broadcast to make the test robust against CSPRNG changes.