123456789101112131415161718192021222324252627282930313233343536373839404142434445 |
- --TEST--
- FPM: Buffered worker output plain log with msg with flush split in buffer
- --SKIPIF--
- <?php include "skipif.inc"; ?>
- --FILE--
- <?php
- require_once "tester.inc";
- $cfg = <<<EOT
- [global]
- error_log = {{FILE:LOG}}
- [unconfined]
- listen = {{ADDR}}
- pm = dynamic
- pm.max_children = 5
- pm.start_servers = 1
- pm.min_spare_servers = 1
- pm.max_spare_servers = 3
- catch_workers_output = yes
- decorate_workers_output = no
- EOT;
- $code = <<<EOT
- <?php
- file_put_contents('php://stderr', str_repeat('a', 1022) . "\0fscf\0");
- EOT;
- $tester = new FPM\Tester($cfg, $code);
- $tester->start();
- $tester->expectLogStartNotices();
- $tester->request()->expectEmptyBody();
- $tester->terminate();
- $tester->expectLogLine(str_repeat('a', 1022), decorated: false);
- $tester->close();
- ?>
- Done
- --EXPECT--
- Done
- --CLEAN--
- <?php
- require_once "tester.inc";
- FPM\Tester::clean();
- ?>
|