mirror of
https://github.com/monero-project/monero.git
synced 2025-06-22 04:14:14 -04:00
add a --fakechain argument for tests
The core tests use the blockchain, and reset it to be able to add test data to it. This does not play nice with the databases, since those will save that data without an explicit save call. We add a fakechain flag that the tests will set, which tells the core and blockchain code to use a separate database, as well as skip a few things like checkpoints and fixup, which only make sense for real data.
This commit is contained in:
parent
eee44e62bc
commit
10da0a0b7c
7 changed files with 27 additions and 8 deletions
|
@ -91,4 +91,9 @@ namespace command_line
|
|||
, "Show time-stats when processing blocks/txs and disk synchronization."
|
||||
, 0
|
||||
};
|
||||
const command_line::arg_descriptor<bool> arg_fakechain = {
|
||||
"fakechain"
|
||||
, "Use a fake chain for testing purposes."
|
||||
, false
|
||||
};
|
||||
}
|
||||
|
|
|
@ -215,4 +215,5 @@ namespace command_line
|
|||
extern const arg_descriptor<uint64_t> arg_prep_blocks_threads;
|
||||
extern const arg_descriptor<uint64_t> arg_db_auto_remove_logs;
|
||||
extern const arg_descriptor<uint64_t> arg_show_time_stats;
|
||||
extern const arg_descriptor<bool> arg_fakechain;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue