[xdebug-general] Re: Code coverage on forked process

From: Derick Rethans <derick[@]xdebug.org>
Date: Fri, 3 Jul 2009 10:24:00 +0100 (BST)

On Fri, 3 Jul 2009, Péter Nagy wrote:

> I'm currently working on a PHP project which uses pcntl_fork() to
> create child process(es) while the code is running. I'm using phpunit
> to test the code which make use of Xdebug's great code coverage
> feature. It seems that either phpunit or xdebug does not collect
> coverage info for the created child process(es).
> I would like to ask your opinion, as I think it should work already
> out-of-the box as the parent process has the coverage report, so
> xdebug and phpunit works fine. As pcntl_fork() creates "copy-on-write"
> process clones I would assume that everything is already set up in the
> child process, so where is the code coverage report gone?

I do not know, I don't think that Xdebug is the culprit here, but
basically that PHP Unit doesn't know how to deal with it. Perhaps
Sebastian (cc-ed) can shed some light on this?

regards,
Derick

-- 
Like Xdebug? Send a postcard: http://derickrethans.nl/xdebug_2_released.php
Xdebug | http://xdebug.org | xdebug-general@lists.xdebug.org
twitter: @derickr and @xdebug
Received on Fri Jul 03 2009 - 11:24:03 BST

This archive was generated by hypermail 2.2.0 : Mon Jun 25 2018 - 06:00:04 BST