feat(test-harness): add --keep-outputs flag and refactor Runner to Options struct (#2942)
* feat(test-harness): add --keep-outputs flag and refactor Runner to use Options struct
Adds a --keep-outputs flag that preserves the work directory (and its
prediction output files like images) after a run, printing the path so
they can be inspected. Also refactors runner.New() from 6 positional
arguments to a runner.Options struct for clarity and extensibility.
* fix(test-harness): fix MIME type detection and convert tests to testify
Fix validateFileExists passing the full file path to mime.TypeByExtension
instead of just the extension, causing MIME checks to always fail.
Convert patcher and validator tests from raw t.Fatal/t.Errorf to
testify assert/require, matching the project convention.
* refactor(test-harness): keep Docker images by default, add --clean-images
Docker image builds are expensive. Keeping them by default avoids
wasteful rebuilds during iterative local development. Replace
--keep-images with --clean-images for when explicit cleanup is wanted.
* Update tools/test-harness/README.md
Co-authored-by: ask-bonk[bot] <249159057+ask-bonk[bot]@users.noreply.github.com>
Signed-off-by: Mark Phelps <209477+markphelps@users.noreply.github.com>
---------
Signed-off-by: Mark Phelps <209477+markphelps@users.noreply.github.com>
Co-authored-by: ask-bonk[bot] <249159057+ask-bonk[bot]@users.noreply.github.com>