1
0
mirror of https://github.com/php/php-src.git synced 2026-03-24 16:22:37 +01:00
Files
archived-php-src/sapi/fpm/tests/status-basic.phpt
Nikita Popov 74075896e1 Revert "Do not check exact values of unstable metrices in FPM status test"
This reverts commit 5b01c4863f.

The previous commit fixes the 32-bit issue. Maybe this one is also
needed, but let's see if any failures of this form turn up first.
2021-03-24 10:07:56 +01:00

51 lines
969 B
PHP

--TEST--
FPM: Status basic test
--SKIPIF--
<?php include "skipif.inc"; ?>
--FILE--
<?php
require_once "tester.inc";
$cfg = <<<EOT
[global]
error_log = {{FILE:LOG}}
[unconfined]
listen = {{ADDR}}
pm = static
pm.max_children = 1
pm.status_path = /status
EOT;
$expectedStatusData = [
'pool' => 'unconfined',
'process manager' => 'static',
'listen queue' => 0,
'max listen queue' => 0,
'idle processes' => 0,
'active processes' => 1,
'total processes' => 1,
'max active processes' => 1,
'max children reached' => 0,
'slow requests' => 0,
];
$tester = new FPM\Tester($cfg);
$tester->start();
$tester->expectLogStartNotices();
$tester->request()->expectEmptyBody();
$tester->status($expectedStatusData);
$tester->terminate();
$tester->expectLogTerminatingNotices();
$tester->close();
?>
Done
--EXPECT--
Done
--CLEAN--
<?php
require_once "tester.inc";
FPM\Tester::clean();
?>