line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Test::Unit::Warning; |
2
|
|
|
|
|
|
|
|
3
|
2
|
|
|
2
|
|
12
|
use strict; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
83
|
|
4
|
2
|
|
|
2
|
|
12
|
use base 'Test::Unit::TestCase'; |
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
427
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
=head1 NAME |
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
Test::Unit::Warning - helper TestCase for adding warnings to a suite |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
=head1 DESCRIPTION |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
Used by L and others to provide messages that |
13
|
|
|
|
|
|
|
come up when the suite runs. |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
=cut |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
sub run_test { |
18
|
1
|
|
|
1
|
0
|
3
|
my $self = shift; |
19
|
1
|
|
|
|
|
13
|
$self->fail($self->{_message}); |
20
|
|
|
|
|
|
|
} |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
sub new { |
23
|
1
|
|
|
1
|
0
|
3
|
my $class = shift; |
24
|
1
|
|
|
|
|
9
|
my $self = $class->SUPER::new('warning'); |
25
|
1
|
|
|
|
|
9
|
$self->{_message} = shift; |
26
|
1
|
|
|
|
|
2
|
return $self; |
27
|
|
|
|
|
|
|
} |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
1; |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
=head1 AUTHOR |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
Copyright (c) 2000-2002, 2005 the PerlUnit Development Team |
35
|
|
|
|
|
|
|
(see L or the F file included in this |
36
|
|
|
|
|
|
|
distribution). |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
All rights reserved. This program is free software; you can |
39
|
|
|
|
|
|
|
redistribute it and/or modify it under the same terms as Perl itself. |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
=cut |
42
|
|
|
|
|
|
|
|