test: Add unit tests for OP_NUMEQUALVERIFY and OP_CHECKMULTISIG #34145

pull billymcbip wants to merge 2 commits into bitcoin:master from billymcbip:num changing 1 files +8 −0
  1. billymcbip commented at 10:47 am on December 24, 2025: contributor

    Add two new test cases to script_tests.json:

    b762538: Add coverage for the error branch of OP_NUMEQUALVERIFY: https://github.com/bitcoin/bitcoin/blob/d861c3820528fad2e17a45549bec70b6ba434dcc/src/script/interpreter.cpp#L997 Note the code coverage miss: https://maflcko.github.io/b-c-cov/total.coverage/src/script/interpreter.cpp.gcov.html

    8dd3db3: Add a test case for OP_CHECKMULTISIG where the dummy element is missing. I used the existing success case as a reference: https://github.com/bitcoin/bitcoin/blob/d861c3820528fad2e17a45549bec70b6ba434dcc/src/test/data/script_tests.json#L1356-L1362

    I ran: cmake -B build -DENABLE_WALLET=OFF && cmake --build build -j 8 && ctest --test-dir build -j 8

  2. DrahtBot added the label Tests on Dec 24, 2025
  3. DrahtBot commented at 10:48 am on December 24, 2025: contributor

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

    Code Coverage & Benchmarks

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

    Reviews

    See the guideline for information on the review process.

    Type Reviewers
    ACK rkrux, bensig

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

  4. DrahtBot added the label CI failed on Dec 24, 2025
  5. billymcbip renamed this:
    test: Add unit test for SCRIPT_ERR_NUMEQUALVERIFY
    test: Add unit tests for OP_NUMEQUALVERIFY and OP_CHECKMULTISIG (easy)
    on Dec 24, 2025
  6. test: Add unit test for SCRIPT_ERR_NUMEQUALVERIFY b762538756
  7. test: Add unit test for missing dummy in OP_CHECKMULTISIG 8dd3db347f
  8. billymcbip force-pushed on Dec 24, 2025
  9. rkrux approved
  10. rkrux commented at 9:56 am on December 26, 2025: contributor

    lgtm crACK 8dd3db347fc199cc819cf9729688faaddbfc441f

    Can mention line 1200 in the PR description that didn’t have coverage until this PR instead of adding the other test case that was referred: https://github.com/bitcoin/bitcoin/blob/d861c3820528fad2e17a45549bec70b6ba434dcc/src/script/interpreter.cpp#L1200

  11. DrahtBot removed the label CI failed on Dec 26, 2025
  12. billymcbip commented at 9:58 am on December 27, 2025: contributor
    @rkrux thanks for the ACK, but that line is dead code, see #33977. The OP_CHECKMULTISIG test case does not improve code coverage, but I think a “missing dummy” test case is good to have.
  13. bensig commented at 9:13 pm on December 31, 2025: contributor

    ACK 8dd3db3

    Built and ran script_tests on macOS - all pass. Both test cases work as expected.

  14. billymcbip commented at 7:40 pm on January 2, 2026: contributor
    Side note: I have another PR out for script_tests: #34099. Thought I’d mention it since it’s within the same context (improving interpreter coverage).
  15. fanquake renamed this:
    test: Add unit tests for OP_NUMEQUALVERIFY and OP_CHECKMULTISIG (easy)
    test: Add unit tests for OP_NUMEQUALVERIFY and OP_CHECKMULTISIG
    on Jan 6, 2026

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-01-07 03:13 UTC

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