run-tests: drop hrtime() polyfill (#16677)

This commit is contained in:
Markus Staab 2024-11-02 10:27:47 +01:00 committed by GitHub
parent 836bd22257
commit cda67fb544
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -784,23 +784,6 @@ function main(): void
} }
} }
if (!function_exists("hrtime")) {
/**
* @return array|float|int
*/
function hrtime(bool $as_num = false)
{
$t = microtime(true);
if ($as_num) {
return $t * 1000000000;
}
$s = floor($t);
return [0 => $s, 1 => ($t - $s) * 1000000000];
}
}
function verify_config(string $php): void function verify_config(string $php): void
{ {
if (empty($php) || !file_exists($php)) { if (empty($php) || !file_exists($php)) {