PEAR 1.4.0dev5 is available - with installable unit tests

From: Date: Tue, 01 Jun 2004 14:56:47 +0000
Subject: PEAR 1.4.0dev5 is available - with installable unit tests
Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-29832@lists.php.net to get a copy of this message
Hi, http://www.chiaraquartet.net/PEAR-1.4.0dev5.tgz includes a bunch of bugfixes to make the unit tests work. I also put some time into making the unit tests installable and workable. The unit tests for PEAR_Downloader use a mock pearweb object to simulate downloading from pearweb and to simulate xml-rpc calls. This means anyone can run any of the tests. To run the tests, grab a copy of the current cvs of php-src/pear/tests., and a copy of run-tests.php from php-src/run-tests.php. Be sure you grab the PHP_4_3 branch of run-tests.php if you want to test in PHP 4!! Then, run $ pear install package-PEARtests.xml note that you have to have the right version of packages installed, like PEAR 1.4.0dev5, or the tests won't install (thank you <dep> tag) You might find it useful to have a little script you can use like this one: <?php putenv('TEST_PHP_EXECUTABLE=C:\php4\cli\php.exe'); putenv('TEST_PHP_DETAILED=1'); if (isset($_SERVER['PHP_SELF'])) {
    echo '<pre>';
} if (isset($_GET['testfile'])) {
    $argv = array();
    $argv[1] = $_GET['testfile'];
    $argc = 2;
} putenv('PHP_PEAR_RUNTESTS=1'); chdir(dirname(__FILE__)); include 'C:/devel/chiara/pear/tests/PEARtests/run-tests.php'; ?> change the paths above or it won't work at all. I use the above script to run the tests in the web browser. To see failed test output, .diff files exist, along with a .exp for expected output, and a .out for actual. Plus, the .phpt spits out a .php file that can be used for those with debuggers to test out why it fails. Hopefully, all the tests will work for you though. Greg

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