test: fix Command::current_dir API
Every single call site wants to pass a path relative to the directory the command was created for. So just make it do that automatically, similar to `Dir::create` and friends.
This commit is contained in:
@@ -154,7 +154,7 @@ test
|
||||
// parent ignore files and manually specified ignore files.
|
||||
let mut cmd = dir.command();
|
||||
cmd.args(&["--ignore-file", "../.not-an-ignore", "-l", "test"]);
|
||||
cmd.current_dir(dir.path().join("baz"));
|
||||
cmd.current_dir("baz");
|
||||
let expected = "
|
||||
baz/bar/test
|
||||
test
|
||||
|
||||
Reference in New Issue
Block a user