Reputation: 32165
So I have a set of unit/integration tests and a set of selenium rc tests as part of my suite. When I run them together using PHPUnit I get a Segmentation fault error message at the very end of the run when, during normal operation, it starts to generate log files. The interesting part is, if I run just the unit tests, or just the selenium rc tests everything works fine. I'm reasonably certain it's not a problem with my code-base because I can visually see all my tests passing. As I said, the error occurs during the results generation phase.
I'm using code-coverage for the unit tests but NOT for the selenium tests (by leaving the $coverageScriptUrl property empty in my selenium objects).
I'm really grasping at straws here because I've never had to diagnose an error with no file or line number. Is there some place I check for some more information? Can someone point me in the right direction? The php error log is empty.
Any ideas?
Upvotes: 2
Views: 1372
Reputation: 95420
If xdebug is causing segfaults, you can switch to using a test coverage tool that doesn't use xdebug at all, just a standard PHP server:
Semantic Designs PHP Test Coverage
Upvotes: 0
Reputation: 401182
I've run into the same kind of trouble, at work, with a colleague : one day, we started having a segfault, with apparently no reason, as the same code was running fine on another machine :-(
We ended up removing code coverage (as it was not that useful to us ; was too low anyway)
Couple of things you could try :
Another thng might be to try with a CVS version of Xdebug 2.1, instead of the the stable 2.0.x ; but not sure that'll help (see http://www.phpunit.de/ticket/513 for instance)
There are a couple of bug reports related to segfaults on Xdebug's Mantis BT ; some of those are not solved.
For instance :
Anyway, good luck...
<(And if you ever find what was causing the problem, I'm interested ;-) )
Upvotes: 3
Reputation: 94237
Segfaults in PHP can definitely be tricky.
As a wild guess, are you running PHPUnit 3.4? It looks like there's a bug reported with Selenium integration just a few weeks ago when using the $this->selectWindow()
call and a null
parameter.
Upvotes: 0