]> git.proxmox.com Git - rustc.git/blob - tests/ui/process/issue-16272.rs
New upstream version 1.68.2+dfsg1
[rustc.git] / tests / ui / process / issue-16272.rs
1 // run-pass
2 // ignore-emscripten no processes
3 // ignore-sgx no processes
4
5 use std::process::Command;
6 use std::env;
7
8 fn main() {
9 let len = env::args().len();
10
11 if len == 1 {
12 test();
13 } else {
14 assert_eq!(len, 3);
15 }
16 }
17
18 fn test() {
19 let status = Command::new(&env::current_exe().unwrap())
20 .arg("foo").arg("")
21 .status().unwrap();
22 assert!(status.success());
23 }