[tap-l] Nested TAP

Andy Armstrong andy at hexten.net
Mon Apr 14 13:55:13 UTC 2008


On 14 Apr 2008, at 13:38, Ovid wrote:
> That's how easy this is.  So far only Michael Peters has spoken up
> about this idea (he points out the issue of return codes).  I'd like  
> to
> hear the opinion of others.


I understand the motives - but it's going to mean that /every/ TAP  
producer from here on is going to carry the burden of being able to  
generate the summary result. That includes producers written in C,  
shell script, assembler.

I'd rather have a clean definition of nested TAP (no summary  
redundancy) and be explicit that it's a new feature that, for now,  
should only be used if you control the whole testing toolchain and can  
upgrade Test::Harness accordingly.

I'm biased - but I can't really get past my original proposal:

ok 1 - foo
begin 2 - nested
1..2
ok 1 - bar
not ok 2 - fribble
end 2 - nested
not ok 3 - fook

That allows TAP to be aggregated just by slapping a begin / end around  
a complete TAP document. I can use cat to aggregate TAP!

I understand the importance of backwards compatibility - but it's just  
one factor. I think we need to compromise. In ten years time I don't  
want to be writing a TAP producer and still have to compute the  
redundant summary result just so that TAP is backwards compatible with  
code nobody uses any more.

-- 
Andy Armstrong, Hexten






More information about the tap-l mailing list