Skip to content
Browse files

More test tweaks to get them working and improve long term stability.

git-svn-id: http://svn.php.net/repository/pear/packages/HTTP_Download/trunk@320870 c90b9560-bf6c-de11-be94-00142212c4b1
  • Loading branch information...
1 parent 3ac986a commit fa79871e2b28e96bb7f5a8a4966843d8cb111f58 Daniel Convissor committed Dec 11, 2011
Showing with 4 additions and 5 deletions.
  1. +1 −1 package.xml
  2. +1 −3 tests/AllTests.php
  3. +2 −1 tests/helper.inc
View
2 package.xml
@@ -53,7 +53,7 @@ DIR layout
<file baseinstalldir="/" md5sum="2925fca8fe2e0b54afca58632dd82195" name="tests/AllTests.php" role="test" />
<file baseinstalldir="HTTP" md5sum="49cb3608e2b33fad6b65df8cb8f49668" name="tests/data.txt" role="test" />
<file baseinstalldir="HTTP" md5sum="ef5bdfce6f4bd82db0ef382512a16d67" name="tests/helper.inc" role="test">
- <tasks:replace from="@include_path@" to="php_dir" type="pear-config" />
+ <tasks:replace from="@php_dir@" to="php_dir" type="pear-config" />
</file>
<file baseinstalldir="/" md5sum="55534b1b8d57d35c46238cfd701a6aa5" name="tests/HTTP_DownloadTest.php" role="test" />
<file baseinstalldir="HTTP" md5sum="20938f4ce9bb39340fd1a6b60c5ca7d2" name="tests/send.php" role="test" />
View
4 tests/AllTests.php
@@ -6,9 +6,7 @@
define('PHPUnit_MAIN_METHOD', 'HTML_Download_AllTests::main');
}
-require_once 'PHPUnit/TextUI/TestRunner.php';
-
-require_once 'HTML_DownloadTest.php';
+require_once dirname(__FILE__) . '/HTML_DownloadTest.php';
class HTML_Download_AllTests
{
View
3 tests/helper.inc
@@ -4,12 +4,13 @@ if ($fp = @fopen('PHPUnit/Autoload.php', 'r', true)) {
require_once 'PHPUnit/Autoload.php';
} elseif ($fp = @fopen('PHPUnit/Framework.php', 'r', true)) {
require_once 'PHPUnit/Framework.php';
+ require_once 'PHPUnit/TextUI/TestRunner.php';
} else {
die('skip could not find PHPUnit');
}
fclose($fp);
-if ('@include_path@' == '@'.'include_path'.'@') {
+if ('@php_dir@' == '@'.'php_dir'.'@') {
// This package hasn't been installed.
// Adjust path to ensure includes find files in working directory.
ini_set('include_path',

0 comments on commit fa79871

Please sign in to comment.
Something went wrong with that request. Please try again.