mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-06-17 01:58:57 +02:00
test: Use BasicTestingSetup when TestingSetup is not necessary
This commit is contained in:
@@ -21,16 +21,16 @@
|
||||
#include <vector>
|
||||
|
||||
/**
|
||||
* Identical to TestingSetup but excludes lock contention logging if
|
||||
* Identical to BasicTestingSetup but excludes lock contention logging if
|
||||
* `DEBUG_LOCKCONTENTION` is defined, as some of these tests are designed to be
|
||||
* heavily contested to trigger race conditions or other issues.
|
||||
*/
|
||||
struct NoLockLoggingTestingSetup : public TestingSetup {
|
||||
struct NoLockLoggingTestingSetup : public BasicTestingSetup {
|
||||
NoLockLoggingTestingSetup()
|
||||
#ifdef DEBUG_LOCKCONTENTION
|
||||
: TestingSetup{ChainType::MAIN, {.extra_args = { "-debugexclude=lock" } }} {}
|
||||
: BasicTestingSetup{ChainType::MAIN, {.extra_args = { "-debugexclude=lock" } }} {}
|
||||
#else
|
||||
: TestingSetup{ChainType::MAIN} {}
|
||||
: BasicTestingSetup{ChainType::MAIN} {}
|
||||
#endif
|
||||
};
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
#include <boost/test/unit_test.hpp>
|
||||
|
||||
BOOST_FIXTURE_TEST_SUITE(merkle_tests, TestingSetup)
|
||||
BOOST_FIXTURE_TEST_SUITE(merkle_tests, BasicTestingSetup)
|
||||
|
||||
static uint256 ComputeMerkleRootFromBranch(const uint256& leaf, const std::vector<uint256>& vMerkleBranch, uint32_t nIndex) {
|
||||
uint256 hash = leaf;
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
|
||||
#include <boost/test/unit_test.hpp>
|
||||
|
||||
BOOST_FIXTURE_TEST_SUITE(orphanage_tests, TestingSetup)
|
||||
BOOST_FIXTURE_TEST_SUITE(orphanage_tests, BasicTestingSetup)
|
||||
|
||||
static void MakeNewKeyWithFastRandomContext(CKey& key, FastRandomContext& rand_ctx)
|
||||
{
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
#include <ranges>
|
||||
#include <vector>
|
||||
|
||||
BOOST_FIXTURE_TEST_SUITE(prevector_tests, TestingSetup)
|
||||
BOOST_FIXTURE_TEST_SUITE(prevector_tests, BasicTestingSetup)
|
||||
|
||||
template <unsigned int N, typename T>
|
||||
class prevector_tester
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
#include <optional>
|
||||
#include <vector>
|
||||
|
||||
BOOST_FIXTURE_TEST_SUITE(rbf_tests, TestingSetup)
|
||||
BOOST_FIXTURE_TEST_SUITE(rbf_tests, BasicTestingSetup)
|
||||
|
||||
static inline CTransactionRef make_tx(const std::vector<CTransactionRef>& inputs,
|
||||
const std::vector<CAmount>& output_values)
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
|
||||
#include <boost/test/unit_test.hpp>
|
||||
|
||||
BOOST_FIXTURE_TEST_SUITE(validation_tests, TestingSetup)
|
||||
BOOST_FIXTURE_TEST_SUITE(validation_tests, BasicTestingSetup)
|
||||
|
||||
static void TestBlockSubsidyHalvings(const Consensus::Params& consensusParams)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user