Fix cli options (#4772)

## Issue Addressed

Fixes breaking change introduced on https://github.com/sigp/lighthouse/pull/4674/  that doesn't allow multiple `http_enabled` `ArgGroup` flags
This commit is contained in:
João Oliveira 2023-09-22 12:00:51 +00:00
parent fbb6997309
commit 0f05499e30
2 changed files with 13 additions and 1 deletions

View File

@ -1273,5 +1273,5 @@ pub fn cli_app<'a, 'b>() -> App<'a, 'b> {
.default_value("64")
.takes_value(true)
)
.group(ArgGroup::with_name("enable_http").args(&["http", "gui", "staking"]))
.group(ArgGroup::with_name("enable_http").args(&["http", "gui", "staking"]).multiple(true))
}

View File

@ -2337,6 +2337,18 @@ fn gui_flag() {
});
}
#[test]
fn multiple_http_enabled_flags() {
CommandLineTest::new()
.flag("gui", None)
.flag("http", None)
.flag("staking", None)
.run_with_zero_port()
.with_config(|config| {
assert!(config.http_api.enabled);
});
}
#[test]
fn optimistic_finalized_sync_default() {
CommandLineTest::new()