chore: style

This commit is contained in:
nuno maduro
2026-05-03 13:06:24 -03:00
parent e0419d1328
commit 6cc48f63f8

View File

@ -1326,7 +1326,7 @@ final class Graph
* test IDs are no longer present (e.g. the test method was removed or renamed). * test IDs are no longer present (e.g. the test method was removed or renamed).
* *
* @param array<int, string> $touchedFiles Absolute or project-relative paths. * @param array<int, string> $touchedFiles Absolute or project-relative paths.
* @param array<int, string> $keepTestIds Test IDs that produced a result this run. * @param array<int, string> $keepTestIds Test IDs that produced a result this run.
*/ */
public function pruneStaleResults(string $branch, array $touchedFiles, array $keepTestIds): void public function pruneStaleResults(string $branch, array $touchedFiles, array $keepTestIds): void
{ {
@ -1351,8 +1351,10 @@ final class Graph
foreach ($this->baselines[$branch]['results'] as $testId => $result) { foreach ($this->baselines[$branch]['results'] as $testId => $result) {
$file = $result['file'] ?? null; $file = $result['file'] ?? null;
if (! is_string($file)) {
if (! is_string($file) || ! isset($touched[$file])) { continue;
}
if (! isset($touched[$file])) {
continue; continue;
} }