On Wed, Aug 20, 2003 at 10:34:08AM +0100, Fergal Daly wrote: > On Wednesday 20 August 2003 08:23, Michael G Schwern wrote: > > You don't want subtests to have to know any state, such as how far to > > indent. Why? Consider: > > Something has to keep state
The state of the overall test? No, that's something which should be avoided. See below. > Later on, I suggested instead something like > > plan 1..3 > plan .1 1..5 > ok .1.1 > ok .1.2 > ok .1.3 > plan .1.4 1..2 > ok .1.4.1 > ok .1.4.2 > ok 1.4 # plan for .1.4 was ok > ok .1.5 > ok .1 # plan for .1 was OK > ok .2 > ok .3 > 1..8 > > A plan counts the number of tests and sub-blocks to expect. The 1..8 at the > end would be calculated by summing the plans of all blocks. I've yet to see a real use-case for plans of plans. It also causes problems with the real use-cases of forking and running a test program from a test program. That cannot be ignored. Work under the assumption that each subplan is not aware of the state of the overall test. This will produce the most useful protocol. -- Michael G Schwern [EMAIL PROTECTED] http://www.pobox.com/~schwern/ I'm going to have to hurt you on principle.