Skip to content

Commit 3da2fb3

Browse files
committed
Add -P option to use the current binary
1 parent ac2d2b9 commit 3da2fb3

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

run-tests.php

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -597,6 +597,15 @@ function save_or_mail_results()
597597
putenv("TEST_PHP_EXECUTABLE=$php");
598598
$environment['TEST_PHP_EXECUTABLE'] = $php;
599599
break;
600+
case 'P':
601+
if(constant('PHP_BINARY')) {
602+
$php = PHP_BINARY;
603+
} else {
604+
break;
605+
}
606+
putenv("TEST_PHP_EXECUTABLE=$php");
607+
$environment['TEST_PHP_EXECUTABLE'] = $php;
608+
break;
600609
case 'q':
601610
putenv('NO_INTERACTION=1');
602611
break;
@@ -686,6 +695,8 @@ function save_or_mail_results()
686695
687696
-p <php> Specify PHP executable to run.
688697
698+
-P Use PHP_BINARY as PHP executable to run.
699+
689700
-q Quiet, no user interaction (same as environment NO_INTERACTION).
690701
691702
-s <file> Write output to <file>.

0 commit comments

Comments
 (0)