[PHPUnit] PHP-Gtk GUI
| From: | Scott Mattocks | Date: | Thu, 11 Nov 2004 13:27:58 +0000 |
| Subject: | [PHPUnit] PHP-Gtk GUI | ||
| Groups: | php.pear.dev | ||
| Request: | Send a blank email to pear-dev+get-34312@lists.php.net to get a copy of this message | ||
Hello,
I have created a PHP-Gtk class for running PHPUnit tests. The source can be downloaded from http://www.crisscott.com/download.php?file=13
I have tried my best to duplicate the features of junit.awtui.testrunner, but there are somethings that cannot be done with PHP4 and PHP-Gtk.
- Reloading the test class on every run. Can't unload a class therefore you can't reload it.
- Can't stop a test in progress.
- Can't color the progress bar red/green to indicate failure/success. (I can get the background to change but I don't think there is a way to make the bar itself change.)
To use the class you just have to instantiate it and call $gui->main().
$gui =& new PHPUnit_GUI_Gtk;
$gui->main();
Once the main window has loaded you can enter the name of a test that has already been declared, or the path to a file containing a test.
Please let me know of any bugs/suggestions/changes.
Thanks,
--
Scott Mattocks
scott@crisscott.com
http://www.crisscott.com