I installed PHPUnit 3.6.10 recently.
I don't understand what is wrong with the include_path in php.ini file
the php.ini files being used are as follows
Configuration File (php.ini) Path: /etc/php5/cli
Loaded Configuration File: /etc/php5/cli/php.ini
Scan for additional .ini files in: /etc/php5/cli/conf.d
Additional .ini files parsed: /etc/php5/cli/conf.d/curl.ini,
/etc/php5/cli/conf.d/mysql.ini,
/etc/php5/cli/conf.d/mysqli.ini,
/etc/php5/cli/conf.d/pdo.ini,
/etc/php5/cli/conf.d/pdo_mysql.ini
another file being used by Apache2 is /etc/php5/apache2/php.ini
I have changed the include paths both in cli/php.ini and apache2/php.ini
the include path which I wrote in php.ini is
include_path = ".:/home/username/pear/share/pear:/usr/share/php
previously the include path was
include_path = .:/usr/share/php:/usr/share/pear
but the error form PHPUnit is this way
PHP Warning: require_once(PHPUnit/Framework.php): failed to open stream: No such file or directory in /home/username/public_html/PHP-Library/APITest.php on line 14
PHP Fatal error: require_once(): Failed opening required 'PHPUnit/Framework.php' (include_path='.:/home/username/pear/share/pear') in /home/username/public_html/PHP-Library/APITest.php on line 14
This is written in the APITest.php file
require_once 'PHPUnit/Framework.php';
Could anybody explain what the problem is? Is there any other place where I need to make changes in php.ini?
Update
when I run below command
$ php -c /path/to/php.ini -r 'echo get_include_path()."\n";'
.:/usr/share/php:/usr/share/pear
update 2 When I remove require and extend PHPUnit_Framework_TestCase I get the following error in apache2 logs I found
[Sun Mar 11 14:54:58 2012] [error] [client 127.0.0.1] PHP Fatal error: Class 'PHPUnit_Framework_TestCase' not found in /home/username/public_html/phplib/APITest.php on line 15
/usr/bin/phpunitandphpunit.phpto see what the standard script does.