PHPT (testfest) writing resources

The PHP TestFest month is almost over and we can already probably say it was quite a success. Of course it would be great if some of the test writers continue to occasionally write a new test or two, and for this occasion, I thought it would be handy to have a resource listing of presentations, websites and pdf’s that cover PHPT testing. Although I believe this is a decent list of resources I’ve actually used myself, I’m probably missing some, so this will be a work in progress and updated once in a while. :-)

First, some of the official PHP resources on PHPT testing (pretty much all of is relevant here):

GCC code coverage page for PHP, which shows test code coverage for the most popular CVS branches. Some graphs and other compiling, testing and analysing information is also available:

This is the place you’ll need to go to acually submit tests if you don’t have CVS commit karma yet (it’s good for overall testing statistics too):

Next is a blog post on what Josie Messa has learned while writing tests. Interesting article which shows a lot of real code examples and issues that she dealt with while writing PHPT tests:

Slides by Sebastian Bergmann, useful to prepare yourself for writing tests. This presentation tells about what PHPT testing is all about, how to properly write tests, and how you should prepare for testfest:

This is an article I wrote, explaining a way to set up Mac OS X for writing PHPT tests. This doesn’t use the built in PHP distribution but instead prepares the OS for manually compiling and running PHP from CVS, with code coverage and all the goodies:

Presentation by Marcus Börger with pretty extensive overview on testing (and PHPT testing in specific). This is one of the most complete presentations on the subject I could find:

The blog of Zoe Slattery, which has 2 posts (and much more to come, undoubtly!) about testing PHP and PHP TestFest:

This is the official website of the PHPT testing framework:

Of course you’re best off grabbing a CVS checkout of the PHP_5_3 (or 6_dev) source tree:

In the CVS checkout of the PHP source code, there is a interesting README file called README.TESTING. It provides useful information on how to test, testing conventions, how to handle failed tests and more:

If you have questions regarding writing PHPT tests, there are several ways to go. First off, you can ask away at the IRC channel #phptestfest on For any kind of QA or testing related question, you can also mail mailing list, and subscribe to the mailing list on

0 Responses to “PHPT (testfest) writing resources”

  • No Comments

Leave a Reply