8000 libtest: Add --report-time flag to print test execution time by jakoschiko · Pull Request #64663 · rust-lang/rust · GitHub
[go: up one dir, main page]

Skip to content

libtest: Add --report-time flag to print test execution time #64663

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Sep 25, 2019
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
libtest: Make --report-time an unstable option
  • Loading branch information
jakoschiko committed Sep 22, 2019
commit d91b965664c47cdf8dfa060f17f50d2fe972c2de
8 changes: 7 additions & 1 deletion src/libtest/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -566,6 +566,13 @@ pub fn parse_opts(args: &[String]) -> Option<OptRes> {
));
}

let report_time = matches.opt_present("report-time");
if !allow_unstable && report_time {
return Some(Err(
"The \"report-time\" flag is only accepted on the nightly compiler".into(),
));
}

let run_ignored = match (include_ignored, matches.opt_present("ignored")) {
(true, true) => {
return Some(Err(
Expand All @@ -579,7 +586,6 @@ pub fn parse_opts(args: &[String]) -> Option<OptRes> {
let quiet = matches.opt_present("quiet");
let exact = matches.opt_present("exact");
let list = matches.opt_present("list");
let report_time = matches.opt_present("report-time");

let logfile = matches.opt_str("logfile");
let logfile = logfile.map(|s| PathBuf::from(&s));
Expand Down
0