Re: pear run-tests annoyances

From: Date: Thu, 05 Jun 2003 15:12:21 +0000
Subject: Re: pear run-tests annoyances
References: 1  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-17079@lists.php.net to get a copy of this message
On Thu, 5 Jun 2003, Mika Tuupola wrote: > It seems the run-tests.php which is used by the command > pear run-tests was designed to run only inside PHP source > tree. For example running tester under own class directory > or pear directory one gets: The patch below fixes the problem. With this patch you actually can run pear run-tests for example in cvs chekcout directory of DB or any other package with .phpt files. Since it is not in pear/ cvs module but php/ i'm not sure if I have enough karma. Can someone verify if the patch is ok and perhaps commit it? -cut- --- run-tests.php 2003-05-24 01:36:20.000000000 +0300 +++ /usr/local/lib/php/run-tests.php 2003-06-05 18:06:04.700009000 +0300 @@ -223,7 +223,9 @@ $test_dirs = array('tests', 'pear', 'ext'); foreach ($test_dirs as $dir) { - find_files("{$cwd}/{$dir}", ($dir == 'ext')); + if (is_dir("{$cwd}/{$dir}")) { + find_files("{$cwd}/{$dir}", ($dir == 'ext')); + } } foreach ($user_tests as $dir) { -cut- -- Mika Tuupola http://www.appelsiini.net/~tuupola/

« previous php.pear.dev (#17079) next »