Ovid wrote:
> ----- Original Message ----
> From: Michael G Schwern <[EMAIL PROTECTED]>
> 
>> Something to consider in all this is that TAPx::Parser
>> needs to know to display what goes to STDERR
>> and suppress what goes to STDOUT.  This means
>> you simply can't mash the two streams together,
>> you have to read them separately and get the order right.
> 
> Agreed that the order has to be correct.  Are you saying that by telling 
> Test::Builder 
> to send everything to the same place that *it* can't get the order right?  
> That seems wrong.  
> All I need is an environment variable I can pass it and this problem seems 
> solved for the time 
> being.  What is about Test::Builder which prevents this?

Well, for one, not everything uses Test::Builder.  Nor do they use the latest 
version of Test::Builder.  Test.pm, for example, also spits to STDERR.  So will 
most home-rolled libraries.  That's because its the only way to get a test to 
display diagnostic information under Test::Harness.  Adding a feature to 
Test::Builder will not solve the problem for you.

It won't work with Test::Builder anyway because of the way TODO tests work.

When a TODO test runs and inevitably fails you don't want the diagnostics to be 
normally displayed to the user but you would like it to show up when run 
verbose or when the raw output is examined.  To accomplish this TODO test 
diagnostics are sent to STDOUT rather than STDERR.  Test::Harness then eats the 
comments.  If everything was mashed into one stream the TAP parser wouldn't 
know what to display and what to suppress.

In order to be compatible with the way tests are currently written you're going 
to have to capture both streams separately and read them in sync.  That's why 
I'm edging you towards not worrying about this right now, its hard.

Reply via email to