Skip to content

Commit 14f5160

Browse files
committed
tests: Require run-pass tests without annotations to run successfully again
1 parent 273f42b commit 14f5160

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/tools/compiletest/src/runtest.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -318,8 +318,10 @@ impl<'test> TestCx<'test> {
318318
}
319319

320320
fn should_run_successfully(&self) -> bool {
321+
let pass_mode = self.pass_mode();
321322
match self.config.mode {
322-
RunPass | Ui => self.pass_mode() == Some(PassMode::Run),
323+
Ui => pass_mode == Some(PassMode::Run),
324+
RunPass => pass_mode == Some(PassMode::Run) || pass_mode.is_none(),
323325
mode => panic!("unimplemented for mode {:?}", mode),
324326
}
325327
}

0 commit comments

Comments
 (0)