X-Git-Url: http://git.vpit.fr/?a=blobdiff_plain;f=lib%2FTest%2FValgrind%2FTool.pm;h=a82b95d676632a0f65c0e6d632375908b6ab3105;hb=943acd9991dfbe73afc5eca6921767f098f5e6a9;hp=9bd530f5a43f17ffc2c64a560b76dc0a22ce5653;hpb=1b06adb9788085e8aad3af42ea384153cd0a4fe6;p=perl%2Fmodules%2FTest-Valgrind.git diff --git a/lib/Test/Valgrind/Tool.pm b/lib/Test/Valgrind/Tool.pm index 9bd530f..a82b95d 100644 --- a/lib/Test/Valgrind/Tool.pm +++ b/lib/Test/Valgrind/Tool.pm @@ -24,7 +24,7 @@ They are expected to function both in suppressions generation and in analysis mo =cut -use base qw/Test::Valgrind::Carp/; +use base qw/Test::Valgrind::Component Test::Valgrind::Carp/; =head1 METHODS @@ -58,7 +58,7 @@ sub new { return $tool->new(%args); } - bless { }, $class; + $class->SUPER::new(@_); } =head2 C @@ -116,7 +116,7 @@ Defaults to the empty list. =cut -sub args { } +sub args { } =head2 C @@ -132,21 +132,20 @@ sub suppressions_tag; Called when the C<$session> starts. -Defaults to void. - -=cut - -sub start { } +Defaults to set L. =head2 C Wraps around either L or L depending on the running mode of the C<$session>. +Croaks if the tool isn't started. =cut sub parse { my ($self, $sess, $fh) = @_; + $self->_croak('Tool isn\'t started') unless $self->started; + if ($sess->do_suppressions) { $self->parse_suppressions($sess, $fh); } else { @@ -178,15 +177,11 @@ sub parse_analysis; Called when the C<$session> finishes. -Defaults to void. - -=cut - -sub finish { } +Defaults to clear L. =head1 SEE ALSO -L, L. +L, L, L. =head1 AUTHOR