Hi...
Maugrim_The_Reaper wrote:
I must admit, it doesn't help when one of the most popular PHP unit testing tutorials (Simpletest Log tut) fails under the current SimpleTest releases since its out of date.
Point taken! I am planning a major tutorial and doc. rewrite in the run up to the 1.0.1 release.
It's a poor excuse, but SimpleTest kind of caught me out. If I ever got 300 downloads a month I was going to be pretty happy

. I've been struggling to catch up ever since, mostly with a constantly changing PHP syntax and minutia of HTTP.
Maugrim_The_Reaper wrote:
No doubt Marcus is really busy (how many projects does the guy run again?) but I hear about that almost as much as the time investment issues.
Nag me again in a month or two. I'm actually cutting back on projects, and forever looking for help with the ones I've got, but I'll be supporting SimpleTest as long as it has a user base. That includes the surrounding tutorials.
Regarding TinyTester, how about stripping it down some more...?
Code: Select all
<?php
ensure(strtolower('Hello') == 'hello');
?>
I am wondering if you cannot let the destruction of a global object could trigger the totals at the end, and the construction could start the page...
Code: Select all
function ensure($condition) {
static $tester;
if (! $tester) {
$tester = new UnitTester();
}
$tester->ensure($condition);
}
class UnitTester {
function __construct() { ... } // Paint header
function __destruct() { ... } // Paint footer
function ensure($condition) { ... } // Adapts to HTML or CLI.
}
I am nowhere near a PHP box to test this, so you might not be able to print anything as the program shuts down. If it works then group tests are just includes.
yours, Marcus