1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-28 11:37:44 +00:00

tests: fix test_ls_path for windows

This commit is contained in:
Anup Mahindre 2021-05-22 14:51:50 +05:30
parent 31545258ac
commit 9f88963764

View file

@ -1992,10 +1992,18 @@ fn test_ls_path() {
.stdout_is(expected_stdout);
let abs_path = format!("{}/{}", at.as_string(), path);
let expected_stdout = &format!("{}\n", abs_path);
let expected_stdout = if cfg!(windows) {
format!("\'{}\'\n", abs_path)
} else {
format!("{}\n", abs_path)
};
scene.ucmd().arg(&abs_path).run().stdout_is(expected_stdout);
let expected_stdout = &format!("{}\n{}\n", path, file1);
let expected_stdout = if cfg!(windows) {
format!("{} {}\n", path, file1)
} else {
format!("{}\n{}\n", path, file1)
};
scene
.ucmd()
.arg(file1)