On Wed, 24 Oct 2007 11:32:27 +0100, Andy Armstrong <[EMAIL PROTECTED]> wrote:

> On 24 Oct 2007, at 11:19, H.Merijn Brand wrote:
> 
> > In chasing down a bug in the CORE test suite, I wanted 'make TEST' to
> > print the TIME next to 'ok' and found that t/TEST already supported a
> > way to show the elapsed time though the $HARNESS_TIMER environment.
> 
> With T::H 2.99 you can
> 
> $ prove -rb --timer
> t/000-load..............1/2 # Testing HTML::Tiny 0.904
> t/000-load..............ok       29 ms
> t/010-simple............ok       42 ms
> t/020-coverage..........ok      307 ms
> t/030-tags..............ok       34 ms
> t/040-lazy..............ok       31 ms
> t/050-validate_tag......ok       27 ms
> All tests successful.
> Files=6, Tests=1151,  1 wallclock secs ( 0.15 usr  0.04 sys +  0.42  
> cusr  0.05 csys =  0.66 CPU)
> Result: PASS
> 
> Do you need the need the full time breakdown (user, system etc)?

No, I needed an absolute time stamp, as in 12:03:58
The test suite didn't cleanup, and I wanted to see which test
left the garbage behind, and if the 'make test' showed the
time, I could quickly reduce my search to the tests that
matched the absolute time

see the last of my three examples:

pc09:/pro/3gl/CPAN/perl-current/t 138 > env HARNESS_TIMER=time ./TEST op/ver.t
t/op/ver....ok 12:18:46
               ^^^^^^^^

> If so we could add a verbose timer option.


-- 
H.Merijn Brand         Amsterdam Perl Mongers (http://amsterdam.pm.org/)
using & porting perl 5.6.2, 5.8.x, 5.10.x  on HP-UX 10.20, 11.00, 11.11,
& 11.23, SuSE 10.1 & 10.2, AIX 5.2, and Cygwin.       http://qa.perl.org
http://mirrors.develooper.com/hpux/            http://www.test-smoke.org
                        http://www.goldmark.org/jeff/stupid-disclaimers/

Reply via email to