#36185 test: add BIP32 vectors 3 and 4 to the extendedkey self-test
https://github.com/bitcoin/bitcoin/pull/36185 · · +15/-0 in 1 files, 1 commits · labels: Tests
Goal
- Verify BIP32 extended key derivation with leading zeros in functional test helpers
- Ensure test framework code handles derivation corner cases properly
This pull request adds test vectors 3 and 4 from BIP32 to the functional test framework's extendedkey self-test in `test/functional/test_framework/extendedkey.py`. These vectors verify that the Python test helper correctly handles leading zeros in private keys and hardened derivation over them.
Problem: The functional test framework's BIP32 implementation only ran test vectors 1 and 2, leaving leading-zero private key corner cases unexercised in the Python self-test.
Category: Test infrastructure (#35 of 45)
P4 · test coverage
- P4 because it adds standard BIP32 test vectors to an internal test helper
- Adds marginal coverage for edge cases without fixing an active bug or enabling new work
Adding test vectors to a Python test framework helper without an active bug or downstream dependency is low-priority maintenance. The author notes that 'Both run against the existing API; no new capability is needed', making it marginal test coverage improvement.
Membership: Modifies test/functional/test_framework/extendedkey.py, testing the Python functional test framework machinery.
Factors: security/stability 0, bug 0, performance 0, user value 0, leverage 0
Reviewability: Ready
- Ready for review
- Small self-contained test addition with passing checks
Clean self-contained 15-line test addition with passing CI and no conflicts.
Author status: active
Agreement: Crickets
- No reviews or comments yet
- Awaiting initial review
No reviews or comments yet.
The PR has had no reviewer comments or reviews since opening.
Review verdicts (DrahtBot): 0
Files
15 lines under test/bench/ci.
- test/functional/test_framework/extendedkey.py +15/-0
Card
Adds BIP32 test vectors 3 and 4 to the functional test framework's Python extendedkey self-test. This exercises handling of leading zeros in private keys within the test helper, which only tested vectors 1 and 2 previously. The change is small (+15 lines) and touches only test framework internal tests. It currently has no reviewer comments or reviews.