]> git.lizzy.rs Git - rust.git/blob - tests/ui/process/process-spawn-nonexistent.rs
Rollup merge of #106717 - klensy:typo, r=lcnr
[rust.git] / tests / ui / process / process-spawn-nonexistent.rs
1 // run-pass
2 // ignore-emscripten no processes
3 // ignore-sgx no processes
4 // ignore-fuchsia ErrorKind not translated
5
6 use std::io::ErrorKind;
7 use std::process::Command;
8
9 fn main() {
10     let result = Command::new("nonexistent").spawn().unwrap_err().kind();
11
12     assert!(matches!(
13         result,
14         // Under WSL with appendWindowsPath=true, this fails with PermissionDenied
15         ErrorKind::NotFound | ErrorKind::PermissionDenied
16     ));
17 }