diff --git a/docs/source/miscellaneous/running-tests.rst b/docs/source/miscellaneous/running-tests.rst index c85e9f4c24dea..bb2c56dcecd25 100644 --- a/docs/source/miscellaneous/running-tests.rst +++ b/docs/source/miscellaneous/running-tests.rst @@ -11,16 +11,16 @@ work). Therefore you can execute the script as follows: .. code:: shell - TEST_PHP_EXECUTABLE=sapi/cli/php \ sapi/cli/php [-c /path/to/php.ini] run-tests.php [ext/foo/tests/GLOB] ****************************************** Which php executable does make test use? ****************************************** -If you are running the ``run-tests.php`` script from the command line (as above) you must set the +If you are running the ``run-tests.php`` script from the command line (as above) you can set the ``TEST_PHP_EXECUTABLE`` environment variable to explicitly select the PHP executable that is to be -tested, that is, used to run the test scripts. +tested, that is, used to run the test scripts, otherwise it will use the PHP CLI binary that you +have compiled (``sapi/cli/php``). If you run the tests using make test, the PHP CLI and CGI executables are automatically set for you. ``make test`` executes ``run-tests.php`` script with the CLI binary. Some test scripts such as @@ -58,6 +58,31 @@ Tester can easily execute tests selectively with as follows: ./sapi/cli/php run-tests.php ext/mbstring/* ./sapi/cli/php run-tests.php ext/mbstring/020.phpt +********************* + Test Runner Options +********************* + +The ``run-tests.php`` test runner has many options. You can see these options by using the ``-h`` +option with ``run-tests.php``. + +You can set options by specifying them on the command line when you run ``php run-tests.php`` or if +you use ``make test`` through the ``TEST_PHP_ARGS`` environment variable: + +.. code:: shell + + php run-tests.php -j24 + # or + TEST_PHP_ARGS="-j24" make test + +Running Tests in Parallel +========================= + +The test runner can run tests in parallel, by using the ``-j`` option: + +.. code:: shell + + php run-tests.php -j24 ext/date/*.phpt + ************** Test results ************** diff --git a/ext/openssl/tests/check_default_conf_path.phpt b/ext/openssl/tests/check_default_conf_path.phpt index 4590ef7804dad..267bebe16c1fa 100644 --- a/ext/openssl/tests/check_default_conf_path.phpt +++ b/ext/openssl/tests/check_default_conf_path.phpt @@ -21,7 +21,7 @@ ob_end_clean(); preg_match(",Openssl default config [^ ]* (.*),", $info, $m); if (isset($m[1])) { - var_dump(str_replace('/', '\\', strtolower($m[1]))); + var_dump(str_replace('\\/', '\\', strtolower($m[1]))); } else { echo $info; }