Description
From what I can tell, ui tests that don't have any //~ ERROR
annotations and have no stderr file are implicitly assumed to require successful compilation. We ought to reject such tests, and instead require an explicit // must-compile-succesfully
comment.
Here are some mentoring instructions. The file that controls the test suite is runtest.rs
. UI tests in particular are controlled by run_ui_test()
:
rust/src/tools/compiletest/src/runtest.rs
Lines 2381 to 2448 in ab79caa
You can see that it begins with a call to compile_test
, but it does not inspect the return value from that function. In contrast, compile-fail
tests check and -- if compilation is successful -- they require that a must_compile_successfully
comment is present:
rust/src/tools/compiletest/src/runtest.rs
Lines 153 to 163 in ab79caa
We want to do something similar, but in the run_ui_test
function. This will likely reveal existing tests that need a // must-compile-successfully
comment.