forked from extern/nushell
Fix path join on streams (#4959)
This commit is contained in:
@ -31,6 +31,18 @@ fn returns_path_joined_from_list() {
|
||||
assert_eq!(actual.out, expected);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn drop_one_path_join() {
|
||||
let actual = nu!(
|
||||
cwd: "tests", pipeline(
|
||||
r#"[a, b, c] | drop 1 | path join
|
||||
"#
|
||||
));
|
||||
|
||||
let expected = join_path_sep(&["a", "b"]);
|
||||
assert_eq!(actual.out, expected);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn appends_slash_when_joined_with_empty_path() {
|
||||
let actual = nu!(
|
||||
|
Reference in New Issue
Block a user