blob: 24e141daef82a11caf8a0e654fec6d56bdd771aa (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
From 7720c13ed242e87ce1e934f80378a6f145ebd769 Mon Sep 17 00:00:00 2001
From: Remi Collet <remi@remirepo.net>
Date: Thu, 9 Jul 2020 07:50:18 +0200
Subject: [PATCH 1/2] improve CGI usage
---
tests/ext/startup_logging.inc | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/tests/ext/startup_logging.inc b/tests/ext/startup_logging.inc
index 17235e11e..869e65da5 100644
--- a/tests/ext/startup_logging.inc
+++ b/tests/ext/startup_logging.inc
@@ -2,8 +2,12 @@
function dd_get_php_cgi()
{
- $executable = dirname(getenv('TEST_PHP_EXECUTABLE')) . '/php-cgi';
- return file_exists($executable) && is_executable($executable) ? $executable : '';
+ $executable = getenv('TEST_PHP_CGI_EXECUTABLE') ?: getenv('TEST_PHP_EXECUTABLE') . '-cgi';
+ if (file_exists($executable) && is_executable($executable)) {
+ $args = getenv('TEST_PHP_ARGS');
+ return $args ? "$executable $args" : "$executable";
+ }
+ return '';
}
function dd_get_startup_logs(array $args = [], array $env = [])
|