mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-05-04 19:08:51 +02:00
Fix ListCoins test failure due to unset g_wallet_allow_fallback_fee
New global variables were introduced in #11882 and not setting them causes: wallet/test/wallet_tests.cpp(638): error in "ListCoins": check wallet->CreateTransaction({recipient}, wtx, reservekey, fee, changePos, error, dummy) failed wallet/test/wallet_tests.cpp(679): error in "ListCoins": check list.begin()->second.size() == 2 failed [1 != 2] wallet/test/wallet_tests.cpp(686): error in "ListCoins": check available.size() == 2 failed [1 != 2] wallet/test/wallet_tests.cpp(705): error in "ListCoins": check list.begin()->second.size() == 2 failed [1 != 2] It's possible to reproduce the failure reliably by running: src/test/test_bitcoin --log_level=test_suite --run_test=wallet_tests/ListCoins Failures happen nondeterministically because boost test framework doesn't run tests in a specified order, and tests that run previously can set the global variables and mask the bug.
This commit is contained in:
@@ -11,8 +11,6 @@ WalletTestingSetup::WalletTestingSetup(const std::string& chainName):
|
||||
TestingSetup(chainName)
|
||||
{
|
||||
bitdb.MakeMock();
|
||||
g_wallet_allow_fallback_fee = true;
|
||||
|
||||
bool fFirstRun;
|
||||
g_address_type = OUTPUT_TYPE_DEFAULT;
|
||||
g_change_type = OUTPUT_TYPE_DEFAULT;
|
||||
|
||||
Reference in New Issue
Block a user