Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Run PHPUnit tests of Symfony 2 application under Netbeans 7.1

I've spent some time to figure out how to configure Netbeans 7.1 to work with Symfony 2 and PHPUnit, but I didn't succeed. When I try to run any test under console, there is no problem. But when running using shift+F6, it returns

"PHP Fatal error: Class 'Symfony\Bundle\FrameworkBundle\Test\WebTestCase' not found"

Does anybody know how to succeed with such kind of configuration?

like image 805
pbuchman Avatar asked Jan 08 '12 22:01

pbuchman


1 Answers

I had the same issue with Netbeans 7.2 This is what I had to do:

  1. Right click on the symfony2 project -> Properties -> PHPUnit
  2. Here check on the "Use Bootstrap" and Browse to the \app\bootstrap.php.cache
  3. Also check on the "Use XML configuration" and Browse to \app\phpunit.xml.dist.

After saving, the ALT+F6 should work

like image 89
Kristóf Dombi Avatar answered Oct 01 '22 01:10

Kristóf Dombi