cvs: pear-core /tests/System test.phpt

From: Date: Sat, 12 Nov 2005 05:41:57 +0000
Subject: cvs: pear-core /tests/System test.phpt
Groups: php.pear.cvs php.pear.core 
Request: Send a blank email to pear-cvs+get-36227@lists.php.net to get a copy of this message
cellog Sat Nov 12 00:41:57 2005 EDT Modified files: /pear-core/tests/System test.phpt Log: fix test so that it works if the ls command is not in /bin (it's in /usr/bin/ls on my system) http://cvs.php.net/diff.php/pear-core/tests/System/test.phpt?r1=1.2&r2=1.3&ty=u Index: pear-core/tests/System/test.phpt diff -u pear-core/tests/System/test.phpt:1.2 pear-core/tests/System/test.phpt:1.3 --- pear-core/tests/System/test.phpt:1.2 Mon Dec 27 02:00:45 2004 +++ pear-core/tests/System/test.phpt Sat Nov 12 00:41:54 2005 @@ -104,11 +104,12 @@ echo "Testing: which\n"; if (OS_UNIX) { - if (System::which('ls') != '/bin/ls') { + $ls = trim(which ls); + if (System::which('ls') != $ls) { print "System::which('ls') failed\n"; } - if (System::which('/bin/ls') != '/bin/ls') { - print "System::which('/bin/ls') failed\n"; + if (System::which($ls) != $ls) { + print "System::which('$ls') failed\n"; } } elseif (OS_WINDOWS) { $sysroot = getenv('SystemRoot') . '\\system32\\';

« previous php.pear.cvs (#36227) next »