Change the default output of --files to elide './'.

This is kind of a ticky-tack change. I do think ./ as a prefix is
reasonable default, *but* we strip ./ when showing search results, so it
does make sense to be consistent.

Fixes #21.
This commit is contained in:
Andrew Gallant
2016-09-24 19:18:48 -04:00
parent af4dc78537
commit 7b860affbe
2 changed files with 5 additions and 5 deletions

View File

@@ -703,11 +703,9 @@ fn files() {
cmd.arg("--files");
let lines: String = wd.stdout(&mut cmd);
if cfg!(windows) {
assert!(lines == "./dir\\file\n./file\n"
|| lines == "./file\n./dir\\file\n");
assert!(lines == "dir\\file\nfile\n" || lines == "file\ndir\\file\n");
} else {
assert!(lines == "./file\n./dir/file\n"
|| lines == "./dir/file\n./file\n");
assert!(lines == "file\ndir/file\n" || lines == "dir/file\nfile\n");
}
}