diff options
| author | Zalathar <Zalathar@users.noreply.github.com> | 2024-09-09 14:11:43 +1000 |
|---|---|---|
| committer | Zalathar <Zalathar@users.noreply.github.com> | 2024-09-09 14:11:43 +1000 |
| commit | a6735e44ca28207d0f2c87c1f47769fed82b56fe (patch) | |
| tree | 65b68255b2c1b6e705bee584cce00d0da9df3b2b | |
| parent | 085744b7ad8b227239bcee0a44cd78dcd0310ab9 (diff) | |
| download | rust-a6735e44ca28207d0f2c87c1f47769fed82b56fe.tar.gz rust-a6735e44ca28207d0f2c87c1f47769fed82b56fe.zip | |
Add an explicit ignore message for "up-to-date" tests
When running tests without the `--force-rerun` flag, compiletest will automatically skip any tests that (in its judgement) don't need to be run again since the last time they were run. This patch adds an explicit reason to those skipped tests, which is visible when running with `rust.verbose-tests = true` in `config.toml`.
| -rw-r--r-- | src/tools/compiletest/src/lib.rs | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/tools/compiletest/src/lib.rs b/src/tools/compiletest/src/lib.rs index 5402e69bc66..3294a3bd080 100644 --- a/src/tools/compiletest/src/lib.rs +++ b/src/tools/compiletest/src/lib.rs @@ -808,8 +808,11 @@ fn make_test( &config, cache, test_name, &test_path, src_file, revision, poisoned, ); // Ignore tests that already run and are up to date with respect to inputs. - if !config.force_rerun { - desc.ignore |= is_up_to_date(&config, testpaths, &early_props, revision, inputs); + if !config.force_rerun + && is_up_to_date(&config, testpaths, &early_props, revision, inputs) + { + desc.ignore = true; + desc.ignore_message = Some("up-to-date"); } test::TestDescAndFn { desc, |
