diff --git a/maa-cli/src/command.rs b/maa-cli/src/command.rs index 392dc9c7..9f6cbde9 100644 --- a/maa-cli/src/command.rs +++ b/maa-cli/src/command.rs @@ -160,7 +160,7 @@ pub(crate) enum Command { #[command(flatten)] common: run::CommonArgs, }, - OperBox { + Operbox { #[command(flatten)] common: run::CommonArgs, }, @@ -666,6 +666,26 @@ mod test { ); } + #[test] + fn depot() { + assert_matches!( + parse_from(["maa", "depot"]).command, + Command::Depot { + common: run::CommonArgs { .. } + } + ); + } + + #[test] + fn operbox() { + assert_matches!( + parse_from(["maa", "operbox"]).command, + Command::Operbox { + common: run::CommonArgs { .. } + } + ); + } + #[test] fn convert() { assert_matches!( diff --git a/maa-cli/src/main.rs b/maa-cli/src/main.rs index 4c1a160b..2ac3119b 100644 --- a/maa-cli/src/main.rs +++ b/maa-cli/src/main.rs @@ -94,7 +94,7 @@ fn main() -> Result<()> { run::run(|_| run::preset::roguelike(theme), common)? } Command::Depot { common } => run::run(|_| run::preset::depot(), common)?, - Command::OperBox { common } => run::run(|_| run::preset::oper_box(), common)?, + Command::Operbox { common } => run::run(|_| run::preset::oper_box(), common)?, Command::Convert { input, output,