Skip to content

Commit d7a533c

Browse files
committed
compiletest: make the crash test error message abit more informative
1 parent 55cac26 commit d7a533c

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src/tools/compiletest/src/runtest.rs

+5-4
Original file line numberDiff line numberDiff line change
@@ -374,11 +374,12 @@ impl<'test> TestCx<'test> {
374374

375375
// if a test does not crash, consider it an error
376376
if proc_res.status.success() || matches!(proc_res.status.code(), Some(1 | 0)) {
377-
self.fatal(
378-
"test no longer crashes/triggers ICE! Please give it a mearningful name, \
377+
self.fatal(&format!(
378+
"Crashtest no longer crashes/triggers ICE, horray! Please give it a meaningful name, \
379379
add a doc-comment to the start of the test explaining why it exists and \
380-
move it to tests/ui or wherever you see fit.",
381-
);
380+
move it to tests/ui or wherever you see fit. Adding 'Fixes #<issueNr>' to your PR body \
381+
ensures that the corresponding ticket is auto-closed upon merge."
382+
));
382383
}
383384
}
384385

0 commit comments

Comments
 (0)