From 1466b8b78ad8cabf93ac3f65f5929213c5dd3c8f Mon Sep 17 00:00:00 2001 From: Gavin Andresen Date: Tue, 11 Oct 2011 19:50:06 -0400 Subject: Rework unit tests so test_bitcoin.cpp does not #include them all --- src/test/test_bitcoin.cpp | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) (limited to 'src/test/test_bitcoin.cpp') diff --git a/src/test/test_bitcoin.cpp b/src/test/test_bitcoin.cpp index 39a7c88e1..c7f45a087 100644 --- a/src/test/test_bitcoin.cpp +++ b/src/test/test_bitcoin.cpp @@ -1,19 +1,8 @@ #define BOOST_TEST_MODULE Bitcoin Test Suite #include -#include "../main.h" -#include "../wallet.h" - -#include "uint160_tests.cpp" -#include "uint256_tests.cpp" -#include "script_tests.cpp" -#include "transaction_tests.cpp" -#include "DoS_tests.cpp" -#include "base64_tests.cpp" -#include "util_tests.cpp" -#include "base58_tests.cpp" -#include "miner_tests.cpp" -#include "Checkpoints_tests.cpp" +#include "main.h" +#include "wallet.h" CWallet* pwalletMain; -- cgit v1.2.3 From cc40ba2151a627b6da9af4932e0bee58e69aacb5 Mon Sep 17 00:00:00 2001 From: Gavin Andresen Date: Mon, 3 Oct 2011 16:14:13 -0400 Subject: Global fixture to send output to console instead of debug.log --- src/test/test_bitcoin.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'src/test/test_bitcoin.cpp') diff --git a/src/test/test_bitcoin.cpp b/src/test/test_bitcoin.cpp index c7f45a087..4b52b74cf 100644 --- a/src/test/test_bitcoin.cpp +++ b/src/test/test_bitcoin.cpp @@ -4,6 +4,16 @@ #include "main.h" #include "wallet.h" +extern bool fPrintToConsole; +struct TestingSetup { + TestingSetup() { + fPrintToConsole = true; // don't want to write to debug.log file + } + ~TestingSetup() { } +}; + +BOOST_GLOBAL_FIXTURE(TestingSetup); + CWallet* pwalletMain; void Shutdown(void* parg) -- cgit v1.2.3