We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 9a734c5 + 7c6985d commit 31b9b65Copy full SHA for 31b9b65
ext/standard/tests/http/bug76342.phpt
@@ -8,9 +8,10 @@ allow_url_fopen=1
8
<?php
9
require 'server.inc';
10
11
+$timeout = 0.5;
12
$options = [
13
'http' => [
- 'timeout' => '0.1',
14
+ 'timeout' => $timeout,
15
],
16
];
17
@@ -20,8 +21,9 @@ $pid = http_server_sleep('tcp://127.0.0.1:12342');
20
21
22
$start = microtime(true);
23
file_get_contents('http://127.0.0.1:12342/', false, $ctx);
-if (microtime(true) - $start >= 0.2) {
24
- echo 'FAIL';
+$diff = microtime(true) - $start;
25
+if ($diff >= 2 * $timeout) {
26
+ echo "FAIL: $diff\n";
27
}
28
29
http_server_kill($pid);
0 commit comments