Block8/PHPCI — pull request #49 by kamermans (2013-05-19 23:01:11+00:00)
Title: Added ability to use custom PHPUnit installation during testing

I use some non standard PHPUnit extensions (like the Selenium extension), and so for my projects, in PHPCI, I use composer to install PHPUnit and the custom extensions, then I can use this updated feature to use my version of PHPUnit instead of the server's version.

Syntax:

php_unit:
config:
- "protected/tests/phpunit.xml.dist"
# Using PHPUnit from Composer since it has the Selenium extension
phpunit_cmd: "protected/vendors/phpunit/phpunit/phpunit.php"

Note that this command will be escaped to prevent shell command injection, prepended with the current build dir, and the entire thing will be passed to the `php` command, so it should be relatively safe.

Basically, from my example above, the executed command for me would be:
`php '/opt/PHPCI/build/project3-build79/protected/vendors/phpunit/phpunit/phpunit.php' -c "/opt/PHPCI/build/project3-build79/protected/tests/phpunit.xml.dist"`