Monero
Loading...
Searching...
No Matches
Macros | Functions
scaling_2021.cpp File Reference
#include "gtest/gtest.h"
#include "cryptonote_core/blockchain.h"
#include "cryptonote_core/tx_pool.h"
#include "cryptonote_core/cryptonote_core.h"
#include "blockchain_db/testdb.h"
Include dependency graph for scaling_2021.cpp:

Macros

#define IN_UNIT_TESTS
 
#define PREFIX_WINDOW(hf_version, window)
 
#define PREFIX(hf_version)   PREFIX_WINDOW(hf_version, TEST_LONG_TERM_BLOCK_WEIGHT_WINDOW)
 

Functions

 TEST (fee_2021_scaling, relay_fee_cases_from_pdf)
 
 TEST (fee_2021_scaling, wallet_fee_cases_from_pdf)
 
 TEST (fee_2021_scaling, rounding)
 

Macro Definition Documentation

◆ IN_UNIT_TESTS

#define IN_UNIT_TESTS

◆ PREFIX

#define PREFIX ( hf_version)    PREFIX_WINDOW(hf_version, TEST_LONG_TERM_BLOCK_WEIGHT_WINDOW)

◆ PREFIX_WINDOW

#define PREFIX_WINDOW ( hf_version,
window )
Value:
std::unique_ptr<cryptonote::Blockchain> bc; \
bc.reset(new cryptonote::Blockchain(txpool)); \
struct get_test_options { \
const std::pair<uint8_t, uint64_t> hard_forks[3]; \
window, \
}; \
get_test_options(): hard_forks{std::make_pair(1, (uint64_t)0), std::make_pair((uint8_t)hf_version, (uint64_t)1), std::make_pair((uint8_t)0, (uint64_t)0)} {} \
} opts; \
bool r = blockchain->init(new TestDB(), cryptonote::FAKECHAIN, true, &opts.test_options, 0, NULL); \
ASSERT_TRUE(r)
Definition blockchain.h:103
Transaction pool, handles transactions which are not part of a block.
Definition tx_pool.h:99
Definition blockchain.py:1
@ FAKECHAIN
Definition cryptonote_config.h:306
Definition enums.h:68
r
Definition testupnpigd.py:61
Definition txpool.py:1
unsigned char uint8_t
Definition stdint.h:124
unsigned __int64 uint64_t
Definition stdint.h:136
Definition cryptonote_core.h:61
Definition chaingen.h:725
const std::pair< uint8_t, uint64_t > hard_forks[2]
Definition chaingen.h:726
const cryptonote::test_options test_options
Definition chaingen.h:727

Function Documentation

◆ TEST() [1/3]

TEST ( fee_2021_scaling ,
relay_fee_cases_from_pdf  )

◆ TEST() [2/3]

TEST ( fee_2021_scaling ,
rounding  )

◆ TEST() [3/3]

TEST ( fee_2021_scaling ,
wallet_fee_cases_from_pdf  )