Skip to content

Commit

Permalink
rustc
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexendoo committed Feb 28, 2024
1 parent da22248 commit c987b43
Showing 1 changed file with 2 additions and 12 deletions.
14 changes: 2 additions & 12 deletions tests/sigabrt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
use std::ffi::{OsStr, OsString};
use std::io::{self, Write};
use std::process::Command;
use std::{env, thread};
use std::thread;
use walkdir::WalkDir;

#[test]
Expand All @@ -16,10 +16,6 @@ fn test() {
}

fn check(thread: usize) {
let current_exe_path = env::current_exe().unwrap();
let deps_path = current_exe_path.parent().unwrap();
let profile_path = deps_path.parent().unwrap();

let mut args = Vec::new();
args.extend(
[
Expand All @@ -32,16 +28,10 @@ fn check(thread: usize) {
.map(OsString::from),
);

let program = profile_path.join(if cfg!(windows) {
"clippy-driver.exe"
} else {
"clippy-driver"
});

for f in WalkDir::new("tests/ui") {
let entry = f.unwrap();
if entry.path().extension() == Some(OsStr::new("rs")) {
let mut c = Command::new(&program);
let mut c = Command::new("rustc");
c.args(&args);
c.arg(entry.path());
c.arg(format!("--out-dir=target/ui-{thread}"));
Expand Down

0 comments on commit c987b43

Please sign in to comment.