forked from extern/nushell
@ -278,6 +278,19 @@ fn run_custom_command_with_rest_and_flag() {
|
||||
assert_eq!(actual.out, r#"["world","hello","yay"]"#);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn run_custom_command_with_empty_rest() {
|
||||
let actual = nu!(
|
||||
cwd: ".",
|
||||
r#"
|
||||
def rest-me-with-empty-rest [...rest: string] { echo $rest }; rest-me-with-empty-rest
|
||||
"#
|
||||
);
|
||||
|
||||
assert_eq!(actual.out, r#""#);
|
||||
assert_eq!(actual.err, r#""#);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn set_variable() {
|
||||
let actual = nu!(
|
||||
|
Reference in New Issue
Block a user