Skip to content

Commit 81b8db2

Browse files
committed
Imply must-compile-successfully in ui-tests when the run-pass flag is present.
1 parent 5990b8b commit 81b8db2

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

src/tools/compiletest/src/header.rs

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -359,10 +359,6 @@ impl TestProps {
359359
self.forbid_output.push(of);
360360
}
361361

362-
if !self.must_compile_successfully {
363-
self.must_compile_successfully = config.parse_must_compile_successfully(ln);
364-
}
365-
366362
if !self.check_test_line_numbers_match {
367363
self.check_test_line_numbers_match = config.parse_check_test_line_numbers_match(ln);
368364
}
@@ -371,6 +367,12 @@ impl TestProps {
371367
self.run_pass = config.parse_run_pass(ln);
372368
}
373369

370+
if !self.must_compile_successfully {
371+
// run-pass implies must_compile_sucessfully
372+
self.must_compile_successfully =
373+
config.parse_must_compile_successfully(ln) || self.run_pass;
374+
}
375+
374376
if let Some(rule) = config.parse_custom_normalization(ln, "normalize-stdout") {
375377
self.normalize_stdout.push(rule);
376378
}

0 commit comments

Comments
 (0)