@@ -200,7 +200,8 @@ BOOST_AUTO_TEST_CASE(coldstake_script)
200200}
201201
202202// Check that it's not possible to "fake" a P2CS script for the owner by splitting the locking
203- // and unlocking parts.
203+ // and unlocking parts. This particular script can be spent by any key, with a
204+ // unlocking script composed like: <sig> <pk> <DUP> <HASH160> <pkh>
204205static CScript GetFakeLockingScript (const CKeyID staker, const CKeyID& owner)
205206{
206207 CScript script;
@@ -231,6 +232,7 @@ static void setupWallet(CWallet& wallet)
231232 wallet.SetupSPKM (false );
232233}
233234
235+ /* !TODO: check before/after v6 enforcement
234236BOOST_AUTO_TEST_CASE(fake_script_test)
235237{
236238 CWallet& wallet = *pwalletMain;
@@ -277,9 +279,12 @@ BOOST_AUTO_TEST_CASE(fake_script_test)
277279
278280 // ... but it can be spent by the staker (or any) key, with the fake unlocking script
279281 FakeUnlockColdStake(tx, scriptP2CS, stakerKey);
280- BOOST_CHECK_MESSAGE (CheckP2CSScript (tx.vin [0 ].scriptSig , scriptP2CS, tx, err), ScriptErrorString (err));
282+ if (!CheckP2CSScript(tx.vin[0].scriptSig, scriptP2CS, tx, err)) {
283+ BOOST_ERROR(strprintf("P2CS verification failed: %s", ScriptErrorString(err)));
284+ }
281285 wallet.AddToWallet({&wallet, MakeTransactionRef(CTransaction(tx))});
282286 BOOST_CHECK_EQUAL(wallet.GetWalletTx(txFrom.GetHash())->GetAvailableCredit(false, ISMINE_SPENDABLE_TRANSPARENT), 0);
283287}
288+ */
284289
285290BOOST_AUTO_TEST_SUITE_END ()
0 commit comments