From 9a841696c1e7147e259e5a387566e461abc144ec Mon Sep 17 00:00:00 2001 From: practicalswift Date: Mon, 24 Jun 2019 17:22:28 +0200 Subject: [PATCH] tests: Reduce compilation time and unneccessary recompiles by removing unused includes in tests --- src/qt/test/addressbooktests.cpp | 1 - src/qt/test/apptests.cpp | 1 - src/qt/test/rpcnestedtests.cpp | 1 - src/qt/test/rpcnestedtests.h | 3 --- src/qt/test/test_main.cpp | 1 - src/test/allocator_tests.cpp | 2 +- src/test/arith_uint256_tests.cpp | 1 - src/test/bip32_tests.cpp | 3 ++- src/test/blockchain_tests.cpp | 1 + src/test/blockencodings_tests.cpp | 2 +- src/test/blockfilter_index_tests.cpp | 1 + src/test/checkqueue_tests.cpp | 3 +-- src/test/coins_tests.cpp | 2 ++ src/test/dbwrapper_tests.cpp | 2 +- src/test/denialofservice_tests.cpp | 2 ++ src/test/flatfile_tests.cpp | 3 +++ src/test/fs_tests.cpp | 1 + src/test/fuzz/deserialize.cpp | 5 +---- src/test/fuzz/fuzz.h | 1 - src/test/fuzz/script_flags.cpp | 1 - src/test/hash_tests.cpp | 3 +-- src/test/key_properties.cpp | 4 ---- src/test/key_tests.cpp | 1 - src/test/mempool_tests.cpp | 2 +- src/test/miner_tests.cpp | 2 +- src/test/multisig_tests.cpp | 1 + src/test/net_tests.cpp | 5 ++++- src/test/policyestimator_tests.cpp | 1 + src/test/pow_tests.cpp | 1 - src/test/raii_event_tests.cpp | 2 -- src/test/rpc_tests.cpp | 2 +- src/test/script_standard_tests.cpp | 1 - src/test/script_tests.cpp | 2 +- src/test/scriptnum10.h | 1 - src/test/serialize_tests.cpp | 1 + src/test/setup_common.cpp | 7 ++++++- src/test/setup_common.h | 2 -- src/test/sigopcount_tests.cpp | 2 +- src/test/streams_tests.cpp | 1 - src/test/transaction_tests.cpp | 1 + src/test/txvalidation_tests.cpp | 2 -- src/test/txvalidationcache_tests.cpp | 4 ---- src/test/uint256_tests.cpp | 6 ++---- src/test/util.cpp | 2 -- src/test/util_tests.cpp | 3 ++- src/test/validation_block_tests.cpp | 3 +++ src/wallet/test/init_test_fixture.cpp | 1 + src/wallet/test/init_tests.cpp | 1 + src/wallet/test/ismine_tests.cpp | 1 - src/wallet/test/psbt_wallet_tests.cpp | 2 -- src/wallet/test/wallet_test_fixture.cpp | 2 -- src/wallet/test/wallet_tests.cpp | 2 -- 52 files changed, 46 insertions(+), 62 deletions(-) diff --git a/src/qt/test/addressbooktests.cpp b/src/qt/test/addressbooktests.cpp index ea1019ad1..11a518ebd 100644 --- a/src/qt/test/addressbooktests.cpp +++ b/src/qt/test/addressbooktests.cpp @@ -12,7 +12,6 @@ #include #include -#include #include #include diff --git a/src/qt/test/apptests.cpp b/src/qt/test/apptests.cpp index 22e49b06c..a900ec019 100644 --- a/src/qt/test/apptests.cpp +++ b/src/qt/test/apptests.cpp @@ -26,7 +26,6 @@ #include #include #include -#include #include #include diff --git a/src/qt/test/rpcnestedtests.cpp b/src/qt/test/rpcnestedtests.cpp index 86e5632e2..eb27d1680 100644 --- a/src/qt/test/rpcnestedtests.cpp +++ b/src/qt/test/rpcnestedtests.cpp @@ -4,7 +4,6 @@ #include -#include #include #include #include diff --git a/src/qt/test/rpcnestedtests.h b/src/qt/test/rpcnestedtests.h index e33f4e3da..97143ff78 100644 --- a/src/qt/test/rpcnestedtests.h +++ b/src/qt/test/rpcnestedtests.h @@ -8,9 +8,6 @@ #include #include -#include -#include - class RPCNestedTests : public QObject { Q_OBJECT diff --git a/src/qt/test/test_main.cpp b/src/qt/test/test_main.cpp index 9f66c3d3a..79d88ab74 100644 --- a/src/qt/test/test_main.cpp +++ b/src/qt/test/test_main.cpp @@ -6,7 +6,6 @@ #include #endif -#include #include #include #include diff --git a/src/test/allocator_tests.cpp b/src/test/allocator_tests.cpp index f25569170..e333763f2 100644 --- a/src/test/allocator_tests.cpp +++ b/src/test/allocator_tests.cpp @@ -2,9 +2,9 @@ // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. +#include #include -#include #include #include diff --git a/src/test/arith_uint256_tests.cpp b/src/test/arith_uint256_tests.cpp index 809c627d2..9ac87261b 100644 --- a/src/test/arith_uint256_tests.cpp +++ b/src/test/arith_uint256_tests.cpp @@ -11,7 +11,6 @@ #include #include #include -#include #include BOOST_FIXTURE_TEST_SUITE(arith_uint256_tests, BasicTestingSetup) diff --git a/src/test/bip32_tests.cpp b/src/test/bip32_tests.cpp index 0c0423c0d..662878750 100644 --- a/src/test/bip32_tests.cpp +++ b/src/test/bip32_tests.cpp @@ -4,9 +4,10 @@ #include +#include #include #include -#include +#include #include #include #include diff --git a/src/test/blockchain_tests.cpp b/src/test/blockchain_tests.cpp index 13afcca37..ca75563ef 100644 --- a/src/test/blockchain_tests.cpp +++ b/src/test/blockchain_tests.cpp @@ -2,6 +2,7 @@ #include +#include #include #include diff --git a/src/test/blockencodings_tests.cpp b/src/test/blockencodings_tests.cpp index f57e1a0eb..dac201a35 100644 --- a/src/test/blockencodings_tests.cpp +++ b/src/test/blockencodings_tests.cpp @@ -6,7 +6,7 @@ #include #include #include -#include +#include #include diff --git a/src/test/blockfilter_index_tests.cpp b/src/test/blockfilter_index_tests.cpp index a9db40547..cf87aa930 100644 --- a/src/test/blockfilter_index_tests.cpp +++ b/src/test/blockfilter_index_tests.cpp @@ -10,6 +10,7 @@ #include #include #include