Changeset View
Changeset View
Standalone View
Standalone View
src/wallet/test/accounting_tests.cpp
Show All 28 Lines | BOOST_AUTO_TEST_CASE(acc_orderupgrade) { | ||||
std::vector<CWalletTx *> vpwtx; | std::vector<CWalletTx *> vpwtx; | ||||
CWalletTx wtx; | CWalletTx wtx; | ||||
CAccountingEntry ae; | CAccountingEntry ae; | ||||
std::map<CAmount, CAccountingEntry> results; | std::map<CAmount, CAccountingEntry> results; | ||||
LOCK(pwalletMain->cs_wallet); | LOCK(pwalletMain->cs_wallet); | ||||
ae.strAccount = ""; | ae.strAccount = ""; | ||||
ae.nCreditDebit = 1; | ae.nCreditDebit = Amount(1); | ||||
ae.nTime = 1333333333; | ae.nTime = 1333333333; | ||||
ae.strOtherAccount = "b"; | ae.strOtherAccount = "b"; | ||||
ae.strComment = ""; | ae.strComment = ""; | ||||
pwalletMain->AddAccountingEntry(ae); | pwalletMain->AddAccountingEntry(ae); | ||||
wtx.mapValue["comment"] = "z"; | wtx.mapValue["comment"] = "z"; | ||||
pwalletMain->AddToWallet(wtx); | pwalletMain->AddToWallet(wtx); | ||||
vpwtx.push_back(&pwalletMain->mapWallet[wtx.GetId()]); | vpwtx.push_back(&pwalletMain->mapWallet[wtx.GetId()]); | ||||
▲ Show 20 Lines • Show All 88 Lines • Show Last 20 Lines |