Skip to content

Commit 2ca6b9d

Browse files
committed
Remove last reference to CWalletDB from accounting_tests.cpp
1 parent 02e2a81 commit 2ca6b9d

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

src/wallet/test/accounting_tests.cpp

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
44

55
#include "wallet/wallet.h"
6-
#include "wallet/walletdb.h"
76

87
#include "wallet/test/wallet_test_fixture.h"
98

@@ -17,7 +16,7 @@ extern CWallet* pwalletMain;
1716
BOOST_FIXTURE_TEST_SUITE(accounting_tests, WalletTestingSetup)
1817

1918
static void
20-
GetResults(CWalletDB& walletdb, std::map<CAmount, CAccountingEntry>& results)
19+
GetResults(std::map<CAmount, CAccountingEntry>& results)
2120
{
2221
std::list<CAccountingEntry> aes;
2322

@@ -32,7 +31,6 @@ GetResults(CWalletDB& walletdb, std::map<CAmount, CAccountingEntry>& results)
3231

3332
BOOST_AUTO_TEST_CASE(acc_orderupgrade)
3433
{
35-
CWalletDB walletdb(pwalletMain->strWalletFile);
3634
std::vector<CWalletTx*> vpwtx;
3735
CWalletTx wtx;
3836
CAccountingEntry ae;
@@ -57,7 +55,7 @@ BOOST_AUTO_TEST_CASE(acc_orderupgrade)
5755
ae.strOtherAccount = "c";
5856
pwalletMain->AddAccountingEntry(ae);
5957

60-
GetResults(walletdb, results);
58+
GetResults(results);
6159

6260
BOOST_CHECK(pwalletMain->nOrderPosNext == 3);
6361
BOOST_CHECK(2 == results.size());
@@ -73,7 +71,7 @@ BOOST_AUTO_TEST_CASE(acc_orderupgrade)
7371
ae.nOrderPos = pwalletMain->IncOrderPosNext();
7472
pwalletMain->AddAccountingEntry(ae);
7573

76-
GetResults(walletdb, results);
74+
GetResults(results);
7775

7876
BOOST_CHECK(results.size() == 3);
7977
BOOST_CHECK(pwalletMain->nOrderPosNext == 4);
@@ -105,7 +103,7 @@ BOOST_AUTO_TEST_CASE(acc_orderupgrade)
105103
vpwtx[2]->nTimeReceived = (unsigned int)1333333329;
106104
vpwtx[2]->nOrderPos = -1;
107105

108-
GetResults(walletdb, results);
106+
GetResults(results);
109107

110108
BOOST_CHECK(results.size() == 3);
111109
BOOST_CHECK(pwalletMain->nOrderPosNext == 6);
@@ -123,7 +121,7 @@ BOOST_AUTO_TEST_CASE(acc_orderupgrade)
123121
ae.nOrderPos = -1;
124122
pwalletMain->AddAccountingEntry(ae);
125123

126-
GetResults(walletdb, results);
124+
GetResults(results);
127125

128126
BOOST_CHECK(results.size() == 4);
129127
BOOST_CHECK(pwalletMain->nOrderPosNext == 7);

0 commit comments

Comments
 (0)