Fixing config values for pruning_history (#2918)
This commit is contained in:
parent
7c6112e9f0
commit
8cef517788
@ -445,6 +445,20 @@ mod tests {
|
||||
assert_eq!(args.flag_chain, "xyz".to_owned());
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn should_use_config_if_cli_is_missing() {
|
||||
let mut config = Config::default();
|
||||
let mut footprint = Footprint::default();
|
||||
footprint.pruning_history = Some(128);
|
||||
config.footprint = Some(footprint);
|
||||
|
||||
// when
|
||||
let args = Args::parse_with_config(&["parity"], config).unwrap();
|
||||
|
||||
// then
|
||||
assert_eq!(args.flag_pruning_history, 128);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn should_parse_full_config() {
|
||||
// given
|
||||
|
@ -225,7 +225,7 @@ Footprint Options:
|
||||
auto - use the method most recently synced or
|
||||
default to fast if none synced (default: {flag_pruning}).
|
||||
--pruning-history NUM Set a number of recent states to keep when pruning
|
||||
is active. [default: {flag_pruning_history}].
|
||||
is active. (default: {flag_pruning_history}).
|
||||
--cache-size-db MB Override database cache size (default: {flag_cache_size_db}).
|
||||
--cache-size-blocks MB Specify the prefered size of the blockchain cache in
|
||||
megabytes (default: {flag_cache_size_blocks}).
|
||||
|
Loading…
Reference in New Issue
Block a user