diff options
| author | Andrew Chin <achin@eminence32.net> | 2014-01-24 19:15:06 -0500 |
|---|---|---|
| committer | Andrew Chin <achin@eminence32.net> | 2014-01-24 19:15:06 -0500 |
| commit | 506c71c980ab97f28e89032c2bba9a471c0b1fd4 (patch) | |
| tree | 6a5514d127fd712287c035db741dae2800e5ea08 /src/libstd | |
| parent | 5675f2813f86ccc6d94251f447661939d9ac3a63 (diff) | |
| download | rust-506c71c980ab97f28e89032c2bba9a471c0b1fd4.tar.gz rust-506c71c980ab97f28e89032c2bba9a471c0b1fd4.zip | |
Use an absolute path in test_process_output_fail_to_start
This test is designed to ensure that running a non-existent executable results in a correct error message (FileNotFound in this case of this test). However, if you try to run an executable that doesn't exist, and that requires searching through the $PATH, and one of the $PATH components is not readable, then a PermissionDenied error will be returned, instead of FileNotFound.
Diffstat (limited to 'src/libstd')
| -rw-r--r-- | src/libstd/run.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libstd/run.rs b/src/libstd/run.rs index f42163791a6..d0ca6efd247 100644 --- a/src/libstd/run.rs +++ b/src/libstd/run.rs @@ -360,7 +360,7 @@ mod tests { trapped_io_error = true; assert_eq!(e.kind, FileNotFound); }).inside(|| -> Option<run::ProcessOutput> { - run::process_output("no-binary-by-this-name-should-exist", []) + run::process_output("/no-binary-by-this-name-should-exist", []) }); assert!(trapped_io_error); assert!(opt_outp.is_none()); |
