core_tests: add tests for hard fork behaviors (MRL-0004)

We also replace the --fakechain option with an optional structure
containing details about configuration for the core/blockchain,
for test purposes. This seems more future friendly.
This commit is contained in:
moneromooo-monero
2016-02-08 18:47:56 +00:00
parent 945fe90e08
commit a333c42cde
10 changed files with 48 additions and 25 deletions

View File

@@ -58,6 +58,7 @@
namespace cryptonote
{
class tx_memory_pool;
struct test_options;
enum blockchain_db_sync_mode
{
@@ -91,8 +92,8 @@ namespace cryptonote
Blockchain(tx_memory_pool& tx_pool);
bool init(BlockchainDB* db, const bool testnet = false, const bool fakechain = false);
bool init(BlockchainDB* db, HardFork*& hf, const bool testnet = false, const bool fakechain = false);
bool init(BlockchainDB* db, const bool testnet = false, const cryptonote::test_options *test_options = NULL);
bool init(BlockchainDB* db, HardFork*& hf, const bool testnet = false);
bool deinit();
void set_checkpoints(checkpoints&& chk_pts) { m_checkpoints = chk_pts; }