test: construct coinselection_tests output declaratively #36888

Manually merged
yuvicc merged 1 commit from test-declarative-coinselection-tests into master 2026-11-20 17:30:42 +00:00 AGit
yuvicc commented 2026-11-16 12:03:19 +00:00 (Migrated from github.com)

Part of #36692:

Build the funding output in MakeCoin() from coinselection_tests with a CTxOut constructor instead of vout.resize(1) followed by assigning nValue. Test-only change, the constructed txns are unchanged and the empty scriptPubKey that resize() left implicit is now explicit.

Part of #36692: Build the funding output in `MakeCoin()` from `coinselection_tests` with a `CTxOut` constructor instead of `vout.resize(1)` followed by assigning `nValue`. Test-only change, the constructed txns are unchanged and the empty `scriptPubKey` that `resize()` left implicit is now explicit.
DrahtBot commented 2026-11-16 12:03:30 +00:00 (Migrated from github.com)

The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

External sites

Reviews

See the guideline and AI policy for information on the review process.

Type Reviewers
ACK alexanderwiederin, maflcko

If your review is incorrectly listed, please copy-paste <!--meta-tag:bot-skip--> into the comment that the bot should ignore.

<!--e57a25ab6845829454e8d69fc972939a--> The following sections might be updated with supplementary metadata relevant to reviewers and maintainers. <!--006a51241073e994b41acfe9ec718e94--> ### External sites * Code coverage & benchmarks: https://corecheck.dev/bitcoin/bitcoin/pulls/36888 * Ralph review <img src=https://review.fish.foo/assets/bitcoin/bitcoin/36888.png alt="Ralph review status"> https://git.fish.foo/bitcoin/bitcoin/pulls/36888#author-ralph <!--021abf342d371248e50ceaed478a90ca--> ### Reviews See [the guideline](https://github.com/bitcoin/bitcoin/blob/master/CONTRIBUTING.md#code-review) and [AI policy](https://github.com/bitcoin/bitcoin/blob/master/doc/AI_POLICY.md) for information on the review process. | Type | Reviewers | | ---- | --------- | | ACK | [alexanderwiederin](https://github.com/bitcoin/bitcoin/pull/36888#pullrequestreview-5953962968), [maflcko](https://github.com/bitcoin/bitcoin/pull/36888#issuecomment-7045615893) | If your review is incorrectly listed, please copy-paste <code>&lt;!--meta-tag:bot-skip--&gt;</code> into the comment that the bot should ignore. <!--5faf32d7da4f0f540f40219e4f7537a3-->
First-time contributor

No verified findings are available from this review.

Review coverage was incomplete.


Reviewed: 77476af7be7a · Review report · Previous reports

permalink

<!-- forgejo-review-bot:bitcoin/bitcoin --> <!-- ralph-engine:current:4da2754fad9950343ec17fdcafb16eba62864da6bb440cd178ec60ac28a60459:4ee3e9bb766c3f5861d94d7c0322dfef3b5c0659d666621aee5388e5750e1b9c --> <!-- ralph-base:29f7e30d547c30ddb7a637bc3a2dbc7c0e3f5469 --> <!-- ralph-head:77476af7be7ad2a9a1abf4e0a82cb7dbcce2fb5f --> <!-- ralph-case:1941e905a3588b7cc7a360bc23c34b1a22419bdbeb22b13315e8acf428fe7b75 --> No verified findings are available from this review. Review coverage was incomplete. <!-- Review tier: routine --> --- Reviewed: [`77476af7be7a`](<https://git.fish.foo/bitcoin/bitcoin/commit/77476af7be7ad2a9a1abf4e0a82cb7dbcce2fb5f>) · [Review report](<https://review.fish.foo/report/36888-77476af7be7ad2a9a1abf4e0a82cb7dbcce2fb5f-2706-1.html>) · [Previous reports](<https://review.fish.foo/traces/36888/>) [permalink](<https://review.fish.foo/report/36888-77476af7be7ad2a9a1abf4e0a82cb7dbcce2fb5f-2706-1.html>)
alexanderwiederin (Migrated from github.com) approved these changes 2026-11-18 09:37:14 +00:00
alexanderwiederin (Migrated from github.com) left a comment

ACK 77476af7be

The output is identical to before: resize(1) left the scriptPubKey empty, which CScript{} now makes explicit.

Built and ran coinselection_tests.

ACK 77476af7be7ad2a9a1abf4e0a82cb7dbcce2fb5f The output is identical to before: `resize(1)` left the scriptPubKey empty, which `CScript{}` now makes explicit. Built and ran `coinselection_tests`.
maflcko commented 2026-11-20 17:05:01 +00:00 (Migrated from github.com)

Same here: I think a 3-line pull is a bit too small:https://github.com/bitcoin/bitcoin/pull/36923#issuecomment-7045346650

review ACK 77476af7be 🍰

Show signature

Signature:

untrusted comment: signature from minisign secret key on empty file; verify via: minisign -Vm "${path_to_any_empty_file}" -P RWTRmVTMeKV5noAMqVlsMugDDCyyTSbA3Re5AkUrhvLVln0tSaFWglOw -x "${path_to_this_whole_four_line_signature_blob}"
RUTRmVTMeKV5npGrKx1nqXCw5zeVHdtdYURB/KlyA/LMFgpNCs+SkW9a8N95d+U4AP1RJMi+krxU1A3Yux4bpwZNLvVBKy0wLgM=
trusted comment: review ACK 77476af7be7ad2a9a1abf4e0a82cb7dbcce2fb5f 🍰
V7CN2aPUikG8MDN6gd00EhzHv/Qd+2oQwR76b5ovR0ydLIS+OpqnUW4N8I0yUbSMjdGtQ/4wAKCQ2vkkQNL/Cw==
Same here: I think a 3-line pull is a bit too small:https://github.com/bitcoin/bitcoin/pull/36923#issuecomment-7045346650 review ACK 77476af7be7ad2a9a1abf4e0a82cb7dbcce2fb5f 🍰 <details><summary>Show signature</summary> Signature: ``` untrusted comment: signature from minisign secret key on empty file; verify via: minisign -Vm "${path_to_any_empty_file}" -P RWTRmVTMeKV5noAMqVlsMugDDCyyTSbA3Re5AkUrhvLVln0tSaFWglOw -x "${path_to_this_whole_four_line_signature_blob}" RUTRmVTMeKV5npGrKx1nqXCw5zeVHdtdYURB/KlyA/LMFgpNCs+SkW9a8N95d+U4AP1RJMi+krxU1A3Yux4bpwZNLvVBKy0wLgM= trusted comment: review ACK 77476af7be7ad2a9a1abf4e0a82cb7dbcce2fb5f 🍰 V7CN2aPUikG8MDN6gd00EhzHv/Qd+2oQwR76b5ovR0ydLIS+OpqnUW4N8I0yUbSMjdGtQ/4wAKCQ2vkkQNL/Cw== ``` </details>
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
bitcoin/bitcoin!36888
No description provided.