chore(harness): run changed suites in CI

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
2026-03-24 18:34:56 +08:00
parent 7b51090823
commit 151d776842
4 changed files with 226 additions and 24 deletions
+35
View File
@@ -94,6 +94,40 @@ function runCommand(command) {
};
}
function printSelection(selection) {
if (selection.suites.length === 0) {
process.stdout.write("[harness] No suites selected for the current diff.\n");
if (selection.unmatchedFiles.length > 0) {
process.stdout.write("[harness] Unmatched files:\n");
for (const filePath of selection.unmatchedFiles) {
process.stdout.write(` - ${filePath}\n`);
}
}
return;
}
process.stdout.write("[harness] Selected suites from changed files:\n");
for (const suiteName of selection.suites) {
process.stdout.write(`- ${suiteName}\n`);
for (const reason of selection.reasons[suiteName] ?? []) {
process.stdout.write(` - ${reason.file}: ${reason.reason}\n`);
}
}
if (selection.unmatchedFiles.length > 0) {
process.stdout.write("[harness] Unmatched files:\n");
for (const filePath of selection.unmatchedFiles) {
process.stdout.write(` - ${filePath}\n`);
}
}
}
const options = parseArgs(process.argv.slice(2));
if (options.list) {
@@ -128,6 +162,7 @@ const report = {
if (selection) {
report.selection = selection;
printSelection(selection);
}
for (const command of commands) {