errors when unit testing

General discussion on Zend Studio
Post Reply
Posts: 61
Joined: Wed Jul 29, 2009 9:04 pm

errors when unit testing

Post by chiefbeef » Sun Jan 20, 2013 9:58 pm

I have created a new zend framework project and am attempting to test my data mappers. They are running when i click on the individual unit test file, but when i right-click the 'phpunit.xml->run as unit test' file to run all the tests, i get this error:
Fatal error: Uncaught exception 'PHPUnit_Framework_Error' with message 'Assigning the return value of new by reference is deprecated
There was a lot of =& in the pear files, so i stripped them out and now am getting this error:
Fatal error: Uncaught exception 'PHPUnit_Framework_Error_Notice' with message 'Non-static method System::tmpdir() should not be called statically' in C:\Zend\ZendServer\bin\PEAR\PEAR\Config.php:158 Stack trace: #0 C:\Zend\ZendServer\bin\PEAR\PEAR\Config.php(158): ZendPHPUnitErrorHandler->handle(2048, 'Non-static meth...', 'C:\Zend\ZendSer...', 158, Array) #1 C:\Zend\ZendServer\bin\PEAR\PEAR\Config.php(158): System::tmpdir() #2 C:\Zend\ZendServer\bin\PEAR\PEAR\RunTest.php(22): require_once('C:\Zend\ZendSer...') #3 C:\Zend\ZendServer\bin\PEAR\PHPUnit\Extensions\PhptTestCase.php(49): require_once('C:\Zend\ZendSer...') #4 C:\Program Files (x86)\Zend\Zend Studio 9.0.4\plugins\com.zend.php.phpunit_9.0.4.201210081806\resources\ZendPHPUnit.php(103): require_once('C:\Zend\ZendSer...') #5 {main} thrown in C:\Zend\ZendServer\bin\PEAR\PEAR\Config.php on line 158
What's going wrong?

I have zend studio 9.0.4 and downgraded to phpunit 3.5.

Post Reply