Before installing PHPUnit on my Ubuntu machine, I thought I had zf.sh all set up correctly. I was able to create a new project without any issues. Now, since installing PHPUnit, everything is not working right.
When I try to create a test project, I get this:
Fatal error: Cannot redeclare class PHPUnit_Framework_TestSuite_DataProvider in /usr/share/php/PHPUnit/Framework/TestSuite/DataProvider.php on line 64
Call Stack:
0.0011 110200 1. {main}() /opt/ZendFramework/ZendFramework-1.9.3PL1-minimal/bin/zf.php:0
0.0011 110320 2. zf_main() /opt/ZendFramework/ZendFramework-1.9.3PL1-minimal/bin/zf.php:23
0.0113 685448 3. zf_run() /opt/ZendFramework/ZendFramework-1.9.3PL1-minimal/bin/zf.php:36
0.0113 685568 4. Zend_Tool_Framework_Client_Console::main() /opt/ZendFramework/ZendFramework-1.9.3PL1-minimal/bin/zf.php:214
0.0114 686044 5. Zend_Tool_Framework_Client_Abstract->dispatch() /opt/ZendFramework/ZendFramework-1.9.3PL1-minimal/library/Zend/Tool/Framework/Client/Console.php:96
0.0114 686164 6. Zend_Tool_Framework_Client_Abstract->initialize() /opt/ZendFramework/ZendFramework-1.9.3PL1-minimal/library/Zend/Tool/Framework/Client/Abstract.php:209
0.0152 866128 7. Zend_Tool_Framework_Loader_Abstract->load() /opt/ZendFramework/ZendFramework-1.9.3PL1-minimal/library/Zend/Tool/Framework/Client/Abstract.php:118
0.4374 2729116 8. include_once('/usr/share/php/PHPUnit/Framework/TestSuite/DataProvider.php') /opt/ZendFramework/ZendFramework-1.9.3PL1-minimal/library/Zend/Tool/Framework/Loader/Abstract.php:90
What do I need to do to get it working again?
Update: I think I understand the reason why this is happening. In PHPUnit 3.4.0 there is a class with the same name as the Zend Framework 1.9.3. Apparently it is a known issue. But how can I get around this so I can use Zend_Tool again?? Can I downgrade PHPUnit? Will that fix the problem?
Update: This tutorial mentions something about installing a diff patch.