aboutsummaryrefslogtreecommitdiff
path: root/src/test/script_standard_tests.cpp
diff options
context:
space:
mode:
authorAndrew Chow <github@achow101.com>2023-08-09 09:46:25 -0400
committerAndrew Chow <github@achow101.com>2023-09-12 12:14:31 -0400
commit07d3bdf4ebc06825ea24ab6f7c87aef6a22238c6 (patch)
tree11a23667794fcd9b4052230f9cfac00e9cb6b00d /src/test/script_standard_tests.cpp
parent1a98a51c666e9ae77364115775ec2e0ba984e8e0 (diff)
Add PubKeyDestination for P2PK scripts
P2PK scripts are not PKHash destinations, they should have their own type. This also results in no longer showing a p2pkh address for p2pk outputs. However for backwards compatibility, ListCoinst will still do this conversion.
Diffstat (limited to 'src/test/script_standard_tests.cpp')
-rw-r--r--src/test/script_standard_tests.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/test/script_standard_tests.cpp b/src/test/script_standard_tests.cpp
index c3d5990e01..58bdb37b7c 100644
--- a/src/test/script_standard_tests.cpp
+++ b/src/test/script_standard_tests.cpp
@@ -203,8 +203,8 @@ BOOST_AUTO_TEST_CASE(script_standard_ExtractDestination)
// TxoutType::PUBKEY
s.clear();
s << ToByteVector(pubkey) << OP_CHECKSIG;
- BOOST_CHECK(ExtractDestination(s, address));
- BOOST_CHECK(std::get<PKHash>(address) == PKHash(pubkey));
+ BOOST_CHECK(!ExtractDestination(s, address));
+ BOOST_CHECK(std::get<PubKeyDestination>(address) == PubKeyDestination(pubkey));
// TxoutType::PUBKEYHASH
s.clear();