refactor: `wallet_importdescriptors` to separate `run_test()` contents into specific functions #36402

pull nebula-21 wants to merge 1 commits into bitcoin:master from nebula-21:refactor-wallet-importdescriptors-test changing 1 files +534 −486
  1. nebula-21 commented at 5:12 PM on October 1, 2026: contributor

    The motivation behind this PR came when reviewing a PR related with wallet_importdescriptors and I noticed that the run_test() function was more than 800 lines of code long, and looked messy and confusing, specially for someone not familiar with that test suite. I believe refactoring the contents inside run_test() and separating it into specific functions would make the test easier to understand and to add new future test cases.

    To review this PR, I recommend using the following command to easily see that the changes are only code movement and function organization:

    git show --color-moved=dimmed-zebra
    

    Suggestions about the new functions, organization, or their order are more than welcome. The approach I took is the one I felt would provide a good balance between keeping the code clean and making the changes as easy as possible to review.

    If reviewers would prefer to split this into multiple commits, I'm also happy to do so.

  2. refactor: `wallet_importdescriptors` to separate `run_test()` contents into specific functions 78d2944944
  3. DrahtBot added the label Refactoring on Oct 1, 2026
  4. DrahtBot commented at 5:12 PM on October 1, 2026: contributor

    <!--e57a25ab6845829454e8d69fc972939a-->

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

    <!--006a51241073e994b41acfe9ec718e94-->

    Code Coverage & Benchmarks

    For details see: https://corecheck.dev/bitcoin/bitcoin/pulls/36402.

    <!--021abf342d371248e50ceaed478a90ca-->

    Reviews

    See the guideline and AI policy for information on the review process. A summary of reviews will appear here.

    <!--5faf32d7da4f0f540f40219e4f7537a3-->

    LLM Linter (✨ experimental)

    Possible places where named args for integral literals may be used (e.g. func(x, /*named_arg=*/0) in C++, and func(x, named_arg=0) in Python):

    • sendtoaddress(...) in test/functional/wallet_importdescriptors.py

    <sup>2026-10-01 17:13:11</sup>

  5. w0xlt commented at 6:26 PM on October 1, 2026: contributor

    Approach aCK


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-10-01 20:51 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me