On Sun, Oct 09, 2005 at 14:15:08 -0700, chromatic wrote: > On Sun, 2005-10-09 at 17:25 +0200, Yuval Kogman wrote: > > > Odd, I wonder why diagnosis are emitted on STDERR (or something else > > maybe). > > That's where Test::Builder emits them. Test::Harness never collected > them or parsed them until recently. > > It's fairly difficult to decide whether a diagnostic is part of a > specific test, so my guess is that writing them to a separate filehandle > avoided that issue.
/me didn't realize that... Pug's Test.pm emits to STDOUT, and since I saw the handles in Straps I used them like that. In TTH any diag after a test case is glued on to that test, and any diag happening before any test has it's own little grey block. I guess I thought that was Good Enough(tm) > I think it would be useful in general, but it's not a guarantee that all > of the information is useful or that any heuristic to identify the > utility of any specific diagnostic would be correct. Arguably it's a good idea if the test writers keep in mind that emitting silly diags is not a good practice if they don't have to do with why a test fails. I'd like to request a feature for Test::Builder to make diag optionally go to STDOUT, controlled via an environment variable as well as a global var or method call to the builder singleton, since it's the behavior I expect in all the tests I write. Right now you can set the failure_output handle (right?) but there is no easy way to say diag_to_stdout. -- () Yuval Kogman <[EMAIL PROTECTED]> 0xEBD27418 perl hacker & /\ kung foo master: /me dodges cabbages like macalypse log N: neeyah!
pgpZtKy70e7US.pgp
Description: PGP signature