Zendcasts Forum

A community of developers who work with the Zend Framework and other enterprise PHP technologies

You are not logged in.

#1 2010-08-21 16:07:05

tajinder.kaur
New member
Registered: 2010-08-20
Posts: 1

How to make PHPUnit refer to the PEAR package in Zend Studio

Hi,

I am deploying phpUnit for the first time to test my php scripts.I installed Zend studio 7.2.1 on Ubuntu machine for creating PHPUnit test cases.I am creating a PHPUnit test case on a class 'User' in the library/ My_library folder which is dependent on another class Entity having the code "PEAR::is_error()".I am storing the test case in the same folder where 'User'class resides , including my application's model classes and running a test case from the zend studio interface.

When I run the test case from zend studio, an error comes in Browser Output:

Fatal error: Class 'PEAR' not found in /var/www/zendBean/library/My_library/Entity.php on line 544

My question is - is it the correct place to store my test script. If yes, do I need to set any include path in the zend studio for the pear package installed in my system. The php.ini of my php5 has the include path as /usr/share/pear but I am not able to access the pear class from the Model class instance.

Last edited by tajinder.kaur (2010-08-21 16:07:33)

Offline

Board footer

Powered by FluxBB