1 # $Header: /home/fergal/my/cvs/Test-Tester/lib/Test/Tester/CaptureRunner.pm,v 1.3 2003/03/05 01:07:55 fergal Exp $
4 package Test::Tester::CaptureRunner;
6 our $VERSION = '1.302133';
9 use Test::Tester::Capture;
15 my $self = bless {}, $pkg;
27 $self->{StartLevel} = $Test::Builder::Level;
34 my @results = capture()->details;
36 my $start = $self->{StartLevel};
37 foreach my $res (@results)
39 next if defined $res->{depth};
40 my $depth = $res->{_depth} - $res->{_level} - $start - 3;
41 # print "my $depth = $res->{_depth} - $res->{_level} - $start - 1\n";
42 $res->{depth} = $depth;
50 return capture()->premature;
55 return Test::Tester::Capture->new;
62 Test::Tester::CaptureRunner - Help testing test modules built with Test::Builder
66 This stuff if needed to allow me to play with other ways of monitoring the
71 Copyright 2003 by Fergal Daly <fergal@esatclear.ie>.
75 Under the same license as Perl itself
77 See http://www.perl.com/perl/misc/Artistic.html