We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Instant::now
1 parent 9f1269f commit 4425148Copy full SHA for 4425148
src/libtest/lib.rs
@@ -563,7 +563,7 @@ fn run_test_in_process(
563
None
564
};
565
566
- let start = report_time.then_some(Instant::now());
+ let start = report_time.then(Instant::now);
567
let result = catch_unwind(AssertUnwindSafe(testfn));
568
let exec_time = start.map(|start| {
569
let duration = start.elapsed();
@@ -594,7 +594,7 @@ fn spawn_test_subprocess(
594
let args = env::args().collect::<Vec<_>>();
595
let current_exe = &args[0];
596
597
598
let output = match Command::new(current_exe)
599
.env(SECONDARY_TEST_INVOKER_VAR, desc.name.as_slice())
600
.output() {
0 commit comments