mirror of
https://github.com/php/php-src.git
synced 2025-08-19 17:04:47 +02:00

FPM must be configured as a user. Normally it defaults to the current user, but if that's root it'll fail to startup unless the --run-as-root option is provided. Extend that logic into the test runner so that we don't fail for stupid reasons. If you're running `make test` as root and you want FPM tests to run anyway, set TEST_FPM_RUN_AS_ROOT=1 in your environment.
17 lines
268 B
PHP
17 lines
268 B
PHP
<?php
|
|
|
|
if (substr(PHP_OS, 0, 3) == 'WIN') {
|
|
die ("skip not for Windows");
|
|
}
|
|
|
|
|
|
if (!getmyuid() && !getenv('TEST_FPM_RUN_AS_ROOT')) {
|
|
die('Refusing to run as root');
|
|
}
|
|
|
|
include dirname(__FILE__)."/include.inc";
|
|
|
|
if (!get_fpm_path()) {
|
|
die("skip FPM not found");
|
|
}
|
|
?>
|