Skip to content

Commit e01e27f

Browse files
committed
Fix cli options (#4772)
## Issue Addressed Fixes breaking change introduced on #4674 that doesn't allow multiple `http_enabled` `ArgGroup` flags
1 parent 9a3674f commit e01e27f

File tree

2 files changed

+12
-1
lines changed

2 files changed

+12
-1
lines changed

beacon_node/src/cli.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1273,5 +1273,5 @@ pub fn cli_app<'a, 'b>() -> App<'a, 'b> {
12731273
.default_value("64")
12741274
.takes_value(true)
12751275
)
1276-
.group(ArgGroup::with_name("enable_http").args(&["http", "gui", "staking"]))
1276+
.group(ArgGroup::with_name("enable_http").args(&["http", "gui", "staking"]).multiple(true))
12771277
}

lighthouse/tests/beacon_node.rs

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2337,6 +2337,17 @@ fn gui_flag() {
23372337
});
23382338
}
23392339

2340+
fn multiple_http_enabled_flags() {
2341+
CommandLineTest::new()
2342+
.flag("gui", None)
2343+
.flag("http", None)
2344+
.flag("staking", None)
2345+
.run_with_zero_port()
2346+
.with_config(|config| {
2347+
assert!(config.http_api.enabled);
2348+
});
2349+
}
2350+
23402351
#[test]
23412352
fn optimistic_finalized_sync_default() {
23422353
CommandLineTest::new()

0 commit comments

Comments
 (0)