diff options
| author | Patrick Steinhardt <ps@pks.im> | 2026-07-13 07:52:04 +0200 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2026-07-13 08:13:16 -0700 |
| commit | 368565e55d5cff377efaee5cf86f092709480314 (patch) | |
| tree | 1c9d21f22f40071776b821ece21800230ef6c050 /t/t4013/diff.diff_initial..side | |
| parent | f85a7e662054a7b0d9070e432508831afa214b47 (diff) | |
t7900: simplify how we check for maintenance tasks
We have several tests in t7900 that verify whether specific maintenance
tasks did or did not run. This is done rather ad-hoc by checking for
spawned Git commands, which is awfully fragile:
- We have to adjust tests whenever arguments to the spawned Git
commands change.
- We don't have a way to verify that negative matches are still
working as expected.
- We rely on maintenance tasks spawning a Git command in the first
place.
We can do much better though, as we already have trace2 regions for each
of the maintenance tasks. Introduce a helper function that extracts all
such regions so that we can get a direct list of all maintenance tasks
that a certain command ran.
Adapt tests that care about whether or not a specific task ran to use
this new helper. Note that many tests still use `test_subcommand`
though, as they really care about the exact command that was executed.
Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t4013/diff.diff_initial..side')
0 files changed, 0 insertions, 0 deletions
