Debugging PHP Unit without IDE/xdebug -


how debug phpunit tests without ide or xdebug? fact phpunit buffers output seems mean must use debugger or ide or use $this->expectoutputstring + print_r() (or whatever) , bunch of comments (since exepcts assertions evaluated last, i've had comment out (failing) assertions).

what's best practice here?

imo xdebug + ide best way debug tests. if want use old fashion method printing on screen use stderr output instead stdout.

for example:

fprintf(stderr, "some label\n"); fprintf(stderr, "array dump: %s\n", var_export($somearray, true)); 

cheers!


Comments

Popular posts from this blog

javascript - DIV "hiding" when changing dropdown value -

Does Firefox offer AppleScript support to get URL of windows? -

android - How to install packaged app on Firefox for mobile? -