summaryrefslogtreecommitdiffstats
path: root/application/third_party/test-more-php/t/testertests_interp_env.php
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xinu.at>2015-02-05 21:38:22 +0100
committerFlorian Pritz <bluewind@xinu.at>2015-02-05 21:38:22 +0100
commita8d1fb52d1dadbd6d4aa4ea50f6f27a967030aa4 (patch)
tree3e1efc5a9d410836afa7601f16358ad9283906cb /application/third_party/test-more-php/t/testertests_interp_env.php
parent6f1258fbf27b05092ed0712c7d20bafda42074ea (diff)
Add Test-More
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to 'application/third_party/test-more-php/t/testertests_interp_env.php')
-rwxr-xr-xapplication/third_party/test-more-php/t/testertests_interp_env.php19
1 files changed, 19 insertions, 0 deletions
diff --git a/application/third_party/test-more-php/t/testertests_interp_env.php b/application/third_party/test-more-php/t/testertests_interp_env.php
new file mode 100755
index 000000000..8c12f0a12
--- /dev/null
+++ b/application/third_party/test-more-php/t/testertests_interp_env.php
@@ -0,0 +1,19 @@
+<?php
+
+ $lib = 'Test-More.php';
+ require_once($lib);
+ $t = new TestMore();
+ $t->plan(1);
+
+ if (strpos(strtoupper($_SERVER['OS']),'WINDOWS') !== FALSE) {
+ // Should also accept extension
+ $newinterp = 'php.exe';
+ } else {
+ // Fair guess
+ $newinterp = '/usr/local/bin/php';
+ }
+
+ $_SERVER['PHP'] = $newinterp;
+ $t->is( $t->interp(),$newinterp,"set valid alternate interp via PHP environment variable ($newinterp)");
+
+?>