Changeset View
Changeset View
Standalone View
Standalone View
src/test/txvalidationcache_tests.cpp
Show First 20 Lines • Show All 194 Lines • ▼ Show 20 Lines | BOOST_FIXTURE_TEST_CASE(checkinputs_test, TestChain100Setup) { | ||||
{ | { | ||||
LOCK(cs_main); | LOCK(cs_main); | ||||
InitScriptExecutionCache(); | InitScriptExecutionCache(); | ||||
} | } | ||||
CScript p2pk_scriptPubKey = | CScript p2pk_scriptPubKey = | ||||
CScript() << ToByteVector(coinbaseKey.GetPubKey()) << OP_CHECKSIG; | CScript() << ToByteVector(coinbaseKey.GetPubKey()) << OP_CHECKSIG; | ||||
CScript p2sh_scriptPubKey = | CScript p2sh_scriptPubKey = | ||||
GetScriptForDestination(CScriptID(p2pk_scriptPubKey)); | GetScriptForDestination(ScriptHash(p2pk_scriptPubKey)); | ||||
CScript p2pkh_scriptPubKey = | CScript p2pkh_scriptPubKey = | ||||
GetScriptForDestination(coinbaseKey.GetPubKey().GetID()); | GetScriptForDestination(PKHash(coinbaseKey.GetPubKey())); | ||||
CBasicKeyStore keystore; | CBasicKeyStore keystore; | ||||
keystore.AddKey(coinbaseKey); | keystore.AddKey(coinbaseKey); | ||||
keystore.AddCScript(p2pk_scriptPubKey); | keystore.AddCScript(p2pk_scriptPubKey); | ||||
CMutableTransaction funding_tx; | CMutableTransaction funding_tx; | ||||
// Needed when spending the output of this transaction | // Needed when spending the output of this transaction | ||||
CScript noppyScriptPubKey; | CScript noppyScriptPubKey; | ||||
▲ Show 20 Lines • Show All 454 Lines • Show Last 20 Lines |