about summary refs log tree commit diff
path: root/tests/ui/command
diff options
context:
space:
mode:
authorCallum Ryan <callumryan@meta.com>2024-10-17 06:33:35 -0700
committerGitHub <noreply@github.com>2024-10-17 06:33:35 -0700
commit9b5b607fd813071ab85d67cae3d6517e3bd586e8 (patch)
tree587006a13b0a18488c32d2bcc0218d4f95eec6e7 /tests/ui/command
parent09f75b9862736d38d41a40c5326788d32c3c8276 (diff)
downloadrust-9b5b607fd813071ab85d67cae3d6517e3bd586e8.tar.gz
rust-9b5b607fd813071ab85d67cae3d6517e3bd586e8.zip
Fix must_use lint for command exec tests
Diffstat (limited to 'tests/ui/command')
-rw-r--r--tests/ui/command/command-exec.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/ui/command/command-exec.rs b/tests/ui/command/command-exec.rs
index c97b8561410..d2545b0b472 100644
--- a/tests/ui/command/command-exec.rs
+++ b/tests/ui/command/command-exec.rs
@@ -26,23 +26,23 @@ fn main() {
             }
 
             "exec-test2" => {
-                Command::new("/path/to/nowhere").exec();
+                let _ = Command::new("/path/to/nowhere").exec();
                 println!("passed");
             }
 
             "exec-test3" => {
-                Command::new(&me).arg("bad\0").exec();
+                let _ = Command::new(&me).arg("bad\0").exec();
                 println!("passed");
             }
 
             "exec-test4" => {
-                Command::new(&me).current_dir("/path/to/nowhere").exec();
+                let _ = Command::new(&me).current_dir("/path/to/nowhere").exec();
                 println!("passed");
             }
 
             "exec-test5" => {
                 env::set_var("VARIABLE", "ABC");
-                Command::new("definitely-not-a-real-binary").env("VARIABLE", "XYZ").exec();
+                let _ =  Command::new("definitely-not-a-real-binary").env("VARIABLE", "XYZ").exec();
                 assert_eq!(env::var("VARIABLE").unwrap(), "ABC");
                 println!("passed");
             }