diff --git a/run-tests.php b/run-tests.php index d772c85f9527..5c1223ad11c8 100755 --- a/run-tests.php +++ b/run-tests.php @@ -3720,9 +3720,14 @@ public function checkSkip(string $php, string $code, string $checkFile, string $ save_text($checkFile, $code, $tempFile); $result = trim(system_with_timeout("$php \"$checkFile\"", $env)); - if (strpos($result, 'nocache') === 0) { - $result = ''; - } else if ($this->enable) { + $cacheResult = $this->enable; + + while (!strncasecmp('nocache', $result, 7)) { + $result = ltrim(substr($result, 7)); + $cacheResult = false; + } + + if ($cacheResult) { $this->skips[$key][$code] = $result; } $this->misses++;