mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-11 22:50:59 +01:00
Change Solver() output for WITNESS_V1_TAPROOT
This is just a small simplification to prepare for the follow-up instruction
of a CTxDestination variant for taproot outputs.
In the old code, WITNESS_V1_TAPROOT and WITNESS_UNKNOWN both produced
{version, program} as Solver() output. Change this so that WITNESS_V1_TAPROOT
produces just {program}, like WITNESS_V0_* do.
This commit is contained in:
@@ -111,9 +111,8 @@ BOOST_AUTO_TEST_CASE(script_standard_Solver_success)
|
||||
s.clear();
|
||||
s << OP_1 << ToByteVector(uint256::ZERO);
|
||||
BOOST_CHECK_EQUAL(Solver(s, solutions), TxoutType::WITNESS_V1_TAPROOT);
|
||||
BOOST_CHECK_EQUAL(solutions.size(), 2U);
|
||||
BOOST_CHECK(solutions[0] == std::vector<unsigned char>{1});
|
||||
BOOST_CHECK(solutions[1] == ToByteVector(uint256::ZERO));
|
||||
BOOST_CHECK_EQUAL(solutions.size(), 1U);
|
||||
BOOST_CHECK(solutions[0] == ToByteVector(uint256::ZERO));
|
||||
|
||||
// TxoutType::WITNESS_UNKNOWN
|
||||
s.clear();
|
||||
|
||||
Reference in New Issue
Block a user