aboutsummaryrefslogtreecommitdiff
path: root/src/test
diff options
context:
space:
mode:
authorAlex Morcos <morcos@chaincode.com>2015-12-04 15:01:22 -0500
committerBtcDrak <btcdrak@gmail.com>2016-03-18 09:14:52 +0000
commitade85e126d1ba7cb90a3382fb8c3cc4f3b89dc4d (patch)
tree8977bfdb2474536bd0868e95a0bca4b0dae791db /src/test
parentc8d309e4b4d82dd233f167b4df503e6a5b4164ef (diff)
Add LockPoints
Obtain LockPoints to store in CTxMemPoolEntry and during a reorg, evaluate whether they are still valid and if not, recalculate them.
Diffstat (limited to 'src/test')
-rw-r--r--src/test/test_bitcoin.cpp2
-rw-r--r--src/test/test_bitcoin.h4
2 files changed, 4 insertions, 2 deletions
diff --git a/src/test/test_bitcoin.cpp b/src/test/test_bitcoin.cpp
index f81050b15d..f278d7e399 100644
--- a/src/test/test_bitcoin.cpp
+++ b/src/test/test_bitcoin.cpp
@@ -150,7 +150,7 @@ CTxMemPoolEntry TestMemPoolEntryHelper::FromTx(CMutableTransaction &tx, CTxMemPo
CAmount inChainValue = hasNoDependencies ? txn.GetValueOut() : 0;
return CTxMemPoolEntry(txn, nFee, nTime, dPriority, nHeight,
- hasNoDependencies, inChainValue, spendsCoinbase, sigOpCount);
+ hasNoDependencies, inChainValue, spendsCoinbase, sigOpCount, lp);
}
void Shutdown(void* parg)
diff --git a/src/test/test_bitcoin.h b/src/test/test_bitcoin.h
index 273bfdd7f4..37bcb9b57c 100644
--- a/src/test/test_bitcoin.h
+++ b/src/test/test_bitcoin.h
@@ -5,6 +5,7 @@
#include "key.h"
#include "pubkey.h"
#include "txdb.h"
+#include "txmempool.h"
#include <boost/filesystem.hpp>
#include <boost/thread.hpp>
@@ -67,7 +68,8 @@ struct TestMemPoolEntryHelper
bool hadNoDependencies;
bool spendsCoinbase;
unsigned int sigOpCount;
-
+ LockPoints lp;
+
TestMemPoolEntryHelper() :
nFee(0), nTime(0), dPriority(0.0), nHeight(1),
hadNoDependencies(false), spendsCoinbase(false), sigOpCount(1) { }