我创建了一个phpunit测试文件,当我尝试通过phpstorm运行它时,我得到消息:
Unable to attach test reporter to test framework or test framework quit unexpectedly 似乎执行了以下命令:
/usr/local/bin/php /private/var/folders/4b/qrnw7nbd6llgmhrss5rf1_880000gt/T/ide-phpunit.php --configuration /Users/Shared/sites/pac/app/app/phpunit.xml.dist BackendControllerTest /Users/Shared/sites/pac/app/modules/Pac/Backend/Tests/Controller/BackendControllerTest.php
Testing started at 23:22 ...
Process finished with exit code 0当我通过命令行执行这个命令时,我得到了更多的输出
PHPUnit 3.6.11 by Sebastian Bergmann.
...etc...
FAILURES!
Tests: 2, Assertions: 2, Failures: 1.似乎phpunit不是在phpstorm中执行的?难道不应该出现某种错误消息,而不是以退出代码0结束吗?phpstorms配置中到php & phpunit (相同)的路径应该是正确的(都是通过/usr/local/bin中的homebrew安装的,路径添加到phpstorm)
osx 10.7.4 php 5.3.14 PHPUnit 3.6.11
谢谢你帮我!
马蒂亚斯
发布于 2012-08-05 20:04:15
在Mac环境变量可在终端和正常的应用程序可以是不同的,check the related question的解决方案如何使他们相似。
请注意,此解决方案will not work on Mountain Lion (10.8)。
发布于 2013-03-07 11:04:07
你在你的php.ini中编辑include_path吗?
我将类似的情况添加到you.After中,我添加了pear的包含路径,它可以工作。
Look at this.
发布于 2014-04-06 05:16:28
在MacOSX上,我被一个类似的问题困扰了很长一段时间。
在我的例子中,原因被证明是一个PHP-upgrade脚本,它扰乱了一些权限。
我做了什么:
中
要查找这些目录,可以执行以下命令
# pear config-show(查找bin_dir和php_dir)
这意味着我将执行以下命令:
# (sudo) chmod -R 755 <bin_dir>
# (sudo) chmod -R 755 <php_dir>更多的代码-更少的IDE-config!
https://stackoverflow.com/questions/11790266
复制相似问题