mirror of
https://github.com/nushell/nushell.git
synced 2025-06-30 06:30:08 +02:00
allow -h
flags for export
subcommands (#6189)
* allow `-h` flags for `export` subcommands * remove unnecessary check * add tests * fmt
This commit is contained in:
15
crates/nu-command/tests/commands/export_def.rs
Normal file
15
crates/nu-command/tests/commands/export_def.rs
Normal file
@ -0,0 +1,15 @@
|
||||
use nu_test_support::{nu, pipeline};
|
||||
|
||||
#[test]
|
||||
fn export_subcommands_help() {
|
||||
let actual = nu!(
|
||||
cwd: ".", pipeline(
|
||||
r#"
|
||||
export def -h
|
||||
"#
|
||||
));
|
||||
|
||||
assert!(actual
|
||||
.out
|
||||
.contains("Define a custom command and export it from a module"));
|
||||
}
|
@ -17,6 +17,7 @@ mod empty;
|
||||
mod enter;
|
||||
mod error_make;
|
||||
mod every;
|
||||
mod export_def;
|
||||
mod find;
|
||||
mod first;
|
||||
mod flatten;
|
||||
|
Reference in New Issue
Block a user