是否可以使用--process-isolation选项调试PhpUnit测试?

Ale*_*lex 7 php phpunit xdebug phpstorm

对于unittest

class SampleTest extends PHPUnit_Framework_TestCase
{
    public function testBreakpoint()
    {
        $a = 18;
    }
}
Run Code Online (Sandbox Code Playgroud)

断点5号线"$ a = 18;",

  • Xdebug v2.1.0,
  • PHPUnit 3.6.10,
  • PHP 5.3.6,
  • ubuntu 10.11

使用NO --process-isolation选项运行unittest可以按预期停止第5行的脚本执行.运行相同的配置WITH --process-isolation选项不会在第5行停止执行.

选项--process-isolation在https://github.com/sebastianbergmann/phpunit/blob/3.6/PHPUnit/Util/PHP.php中的runJob函数中使用'proc_open'运行新进程中的每个测试

使用调试器插件测试PhpStorm 3和vim 7.它允许调试PHPUnit本身,但不允许调试测试用例.

有没有办法使用Xdebug调试由PhpUnit创建的子进程?可能是Zend Debugger?

Sam*_*ssy 2

正如该问题的评论中所述。问题是PHP Storm 不支持多个并行调试会话