diff options
author | MarcoFalke <falke.marco@gmail.com> | 2021-04-14 10:30:01 +0200 |
---|---|---|
committer | MarcoFalke <falke.marco@gmail.com> | 2021-04-14 17:38:07 +0200 |
commit | fa40d6a1c47ac7f3dc6c11a2e6642cfef95422c1 (patch) | |
tree | 9dbce99e4f02d4b59e8889f0cb607c88fcecaab3 /src/test/util | |
parent | fa78590a8fffdfc7e98ddb1f81218f05b1935a0a (diff) |
test: Reset mocktime in the common setup
Doing it there will reduce code bloat and also ensure no test can "forget" to reset it
Diffstat (limited to 'src/test/util')
-rw-r--r-- | src/test/util/setup_common.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/test/util/setup_common.cpp b/src/test/util/setup_common.cpp index 2d7f335a04..d644dd2327 100644 --- a/src/test/util/setup_common.cpp +++ b/src/test/util/setup_common.cpp @@ -120,6 +120,7 @@ BasicTestingSetup::BasicTestingSetup(const std::string& chainName, const std::ve BasicTestingSetup::~BasicTestingSetup() { + SetMockTime(0s); // Reset mocktime for following tests LogInstance().DisconnectTestLogger(); fs::remove_all(m_path_root); gArgs.ClearArgs(); @@ -303,7 +304,6 @@ CMutableTransaction TestChain100Setup::CreateValidMempoolTransaction(CTransactio TestChain100Setup::~TestChain100Setup() { gArgs.ForceSetArg("-segwitheight", "0"); - SetMockTime(0); } CTxMemPoolEntry TestMemPoolEntryHelper::FromTx(const CMutableTransaction& tx) const |