Electroneum
transaction_tests.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

bool test_transactions ()
 
bool test_block_creation ()
 

Function Documentation

◆ test_block_creation()

bool test_block_creation ( )

Definition at line 136 of file transaction_tests.cpp.

137 {
138  uint64_t vszs[] = {80,476,476,475,475,474,475,474,474,475,472,476,476,475,475,474,475,474,474,475,472,476,476,475,475,474,475,474,474,475,9391,476,476,475,475,474,475,8819,8301,475,472,4302,5316,14347,16620,19583,19403,19728,19442,19852,19015,19000,19016,19795,19749,18087,19787,19704,19750,19267,19006,19050,19445,19407,19522,19546,19788,19369,19486,19329,19370,18853,19600,19110,19320,19746,19474,19474,19743,19494,19755,19715,19769,19620,19368,19839,19532,23424,28287,30707};
139  std::vector<uint64_t> szs(&vszs[0], &vszs[90]);
141  bool r = get_account_address_from_str(info, MAINNET, "0099be99c70ef10fd534c43c88e9d13d1c8853213df7e362afbec0e4ee6fec4948d0c190b58f4b356cd7feaf8d9d0a76e7c7e5a9a0a497a6b1faf7a765882dd08ac2");
142  CHECK_AND_ASSERT_MES(r, false, "failed to import");
143  block b;
144  r = construct_miner_tx(90, epee::misc_utils::median(szs), 3553616528562147, 33094, 10000000, info.address, b.miner_tx, blobdata(), 11);
145  return r;
146 }
#define CHECK_AND_ASSERT_MES(expr, fail_ret_val, message)
Definition: misc_log_ex.h:181
unsigned __int64 uint64_t
Definition: stdint.h:136
std::string blobdata
Definition: blobdatatype.h:39
type_vec_type median(std::vector< type_vec_type > &v)
CXA_THROW_INFO_T * info
Definition: stack_trace.cpp:91
bool get_account_address_from_str(address_parse_info &info, network_type nettype, std::string const &str)
bool construct_miner_tx(size_t height, size_t median_weight, uint64_t already_generated_coins, size_t current_block_weight, uint64_t fee, const account_public_address &miner_address, transaction &tx, const blobdata &extra_nonce, size_t max_outs, uint8_t hard_fork_version, network_type nettype)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ test_transactions()

bool test_transactions ( )

Definition at line 148 of file transaction_tests.cpp.

149 {
151  return false;
152  if(!test_block_creation())
153  return false;
154 
155 
156  return true;
157 }
bool test_transaction_generation_and_ring_signature()
bool test_block_creation()
Here is the call graph for this function:
Here is the caller graph for this function: