Andy Lester wrote:
On Mar 3, 2007, at 8:15 PM, Eric Wilhelm wrote:

Yeah, you have to remember to put it at the end of the file, but it may
be easier than counting tests.

Good Lord do I get frustrated at the handwringing over test counting. Look, it's simple. You write your tests. You run it through prove. You see how many tests it reports. You add it at the top of the file. Voila!

I don't know how many times I've used that approach and shipped code with the wrong count in the SKIP blocks. See, they don't get run on my machine so your empirical approach does not work. Followed closely by a bug report from a Windows user because the test count is wrong, assurances from me that there's not a real bug and everything's ok and then a new release the next day.

Bleh, such work and flapping around.


All of this flapping about how maybe we should come up with some mechanisms to do test counting and blah blah blah is like buying a computer to store your recipes on instead of grandma's 3x5 index cards. They ain't sexy but they WORK.

If the computer is free and easy to use then its sensible. Test::Builder is free, we're just making it a little easier to use.

Its O(1) vs O(n). We do the work once to make "no plan" safer, everybody benefits for happily ever after. Your argument sounds like the things I had to deal with when I introduced Test::More. "Why should we load a module with all these functions when I can just write 'print ...my test... ? "ok 1\n" : "not ok 1\n";'?"

Anyhow, not to argue by fiat, but I like the "no plan" concept and I prefer providing flexibility in a test framework and I control Test::Builder so "no plan" is here to stay. Patches welcome.

Reply via email to