test: check that combining PSBTs with different txs fails#25670
Merged
achow101 merged 2 commits intobitcoin:masterfrom Jul 28, 2022
Merged
test: check that combining PSBTs with different txs fails#25670achow101 merged 2 commits intobitcoin:masterfrom
achow101 merged 2 commits intobitcoin:masterfrom
Conversation
d79d846 to
b4f3322
Compare
Contributor
Author
|
Force-pushed a different variant of the first commit (extending the PSBT ctor), avoiding mutable objects as default parameters due to the following linter complaint: |
instagibbs
approved these changes
Jul 22, 2022
Member
instagibbs
left a comment
There was a problem hiding this comment.
ACK b4f332275c593d5c8f454f3e2b7f5d491ef4f520
This will allow to create simple PSBTs as short one-liners, without the need to have three individual assignments (globals, inputs, outputs).
b4f3322 to
16a0b28
Compare
Contributor
Author
|
Force-pushed with changes as suggested by @instagibbs (named arguments for PSBT ctor, adding call for success case of combining two identical PSBTs). |
16a0b28 to
4e616d2
Compare
Member
|
reACK 4e616d2 |
Member
|
ACK 4e616d2 |
sidhujag
pushed a commit
to syscoin/syscoin
that referenced
this pull request
Jul 29, 2022
…txs fails 4e616d2 test: check that combining PSBTs with different txs fails (Sebastian Falbesoner) 2a428c7 test: support passing PSBTMaps directly to PSBT ctor (Sebastian Falbesoner) Pull request description: This PR adds missing test coverage for the `combinepsbt` RPC, in the case of combining two PSBTs with different transactions: https://github.com/bitcoin/bitcoin/blob/b8067cd435059eedb580975afc62c4e7a6f27321/src/psbt.cpp#L24-L27 The calling function `CombinePSBTs` checks for the false return value and then returns the transaction error string `PSBT_MISMATCH`: https://github.com/bitcoin/bitcoin/blob/b8067cd435059eedb580975afc62c4e7a6f27321/src/psbt.cpp#L433-L435 https://github.com/bitcoin/bitcoin/blob/b8067cd435059eedb580975afc62c4e7a6f27321/src/util/error.cpp#L30-L31 ACKs for top commit: instagibbs: reACK bitcoin@4e616d2 achow101: ACK 4e616d2 Tree-SHA512: 45b2b224b13b44ad69ae62e4bc20f74cab32770cf8127b026ec47a7520f7253148fdbf1fad612afece59e45a6738bef9a351ae87ea98dc83d095cc78f6db0318
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR adds missing test coverage for the
combinepsbtRPC, in the case of combining two PSBTs with different transactions:bitcoin/src/psbt.cpp
Lines 24 to 27 in b8067cd
The calling function
CombinePSBTschecks for the false return value and then returns the transaction error stringPSBT_MISMATCH:bitcoin/src/psbt.cpp
Lines 433 to 435 in b8067cd
bitcoin/src/util/error.cpp
Lines 30 to 31 in b8067cd