Require file tests to specify a min-prelude (#5818)

Use `full.carbon` min-prelude for any tests using the full prelude. A
few tests were using it unnecessarily and are changed to a more minimal
one in the process.

Any test which does not include some min-prelude will now fail with an
error.
This commit is contained in:
Dana Jansens
2025-07-18 16:26:12 +00:00
committed by GitHub
parent 2658142f7b
commit bcba76aca7
69 changed files with 1418 additions and 1387 deletions
+3 -5
View File
@@ -163,11 +163,9 @@ auto ToolchainFileTest::Run(
}
}
if (!found_prelude_flag) {
// TODO: Enable this error when all check/ and lower/ tests include a
// prelude choice explicitly.
// return Error(
// "Include a prelude from //toolchain/testing/testdata/min_prelude "
// "to specify what should be imported into the test.");
return Error(
"Include a prelude from //toolchain/testing/testdata/min_prelude "
"to specify what should be imported into the test.");
}
} else {
filtered_test_args = test_args;