I just made a testrun so see if I can get it working. Getting the tests to run revealed the following TODO:
Next to this things left to do, I offer some documentation so that you can get a faster start right away.
Before you can run the WordPress Testing Framework you need to match the requirements.
Mainly the tests require PHPUnit. But PHPUnit itself is based on other components, so these are:
Install with go-pear if you do not have it already. After installation spend it an update:
pear upgrade PEAR
This is always a good idea for PEAR and the PHPUnit installation would otherwise reveal a lot of warning and problems.
XDebug installation instructions, would be either by donwloading a binary or by
# pecl install xdebug (some systems only). Must be configured in PHP.ini afterwards.
PHPUnit Installation as easy as:
pear channel-discover pear.phpunit.de
pear channel-discover components.ez.no
pear channel-discover pear.symfony-project.com
pear install –alldeps phpunit/PHPUnit
After fulfilling the requirements, you can obtain the testing framework as described here. Basically all you need is to checkout the tests from SVN and to create a database and a wp-config.php. Then you're ready to run tests.
A full metric can be created by combining codesniffer and unittests output: http://github.com/beberlei/puma/tree/master next to this, validation of HTML output could be measured as well (not covered by that link). in case of untestable code, runkit might come to the help (http://www.whitewashing.de/blog/articles/115).