1
0
Fork 0
forked from lthn/blockchain

coretests: construct_tx_with_many_outputs made familiar with ref_by_id

This commit is contained in:
sowle 2021-01-08 23:52:46 +03:00
parent 00976d5f65
commit e625539758
No known key found for this signature in database
GPG key ID: C07A24B2D89D49FC
2 changed files with 3 additions and 3 deletions

View file

@ -1548,10 +1548,10 @@ transaction construct_tx_with_fee(std::vector<test_event_entry>& events, const b
bool construct_tx_with_many_outputs(std::vector<test_event_entry>& events, const currency::block& blk_head,
const currency::account_keys& keys_from, const currency::account_public_address& addr_to,
uint64_t total_amount, size_t outputs_count, uint64_t fee, currency::transaction& tx)
uint64_t total_amount, size_t outputs_count, uint64_t fee, currency::transaction& tx, bool use_ref_by_id /* = false */)
{
std::vector<currency::tx_source_entry> sources;
bool r = fill_tx_sources(sources, events, blk_head, keys_from, total_amount + fee, 0, true, false, false);
bool r = fill_tx_sources(sources, events, blk_head, keys_from, total_amount + fee, 0, true, false, use_ref_by_id);
CHECK_AND_ASSERT_MES(r, false, "fill_tx_sources failed");
std::vector<currency::tx_destination_entry> destinations;

View file

@ -599,7 +599,7 @@ currency::transaction construct_tx_with_fee(std::vector<test_event_entry>& event
bool construct_tx_with_many_outputs(std::vector<test_event_entry>& events, const currency::block& blk_head,
const currency::account_keys& keys_from, const currency::account_public_address& addr_to,
uint64_t total_amount, size_t outputs_count, uint64_t fee, currency::transaction& tx);
uint64_t total_amount, size_t outputs_count, uint64_t fee, currency::transaction& tx, bool use_ref_by_id = false);
void get_confirmed_txs(const std::vector<currency::block>& blockchain, const map_hash2tx_t& mtx, map_hash2tx_t& confirmed_txs);
bool find_block_chain(const std::vector<test_event_entry>& events, std::vector<currency::block>& blockchain, map_hash2tx_t& mtx, const crypto::hash& head);