line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
1
|
|
|
1
|
|
7
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
31
|
|
2
|
1
|
|
|
1
|
|
5
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
37
|
|
3
|
|
|
|
|
|
|
|
4
|
|
|
|
|
|
|
package Test::Deep::Code 1.204; |
5
|
|
|
|
|
|
|
|
6
|
1
|
|
|
1
|
|
371
|
use Test::Deep::Cmp; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
4
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
sub init |
9
|
|
|
|
|
|
|
{ |
10
|
3
|
|
|
3
|
0
|
5
|
my $self = shift; |
11
|
|
|
|
|
|
|
|
12
|
3
|
|
50
|
|
|
9
|
my $code = shift || die "No coderef supplied"; |
13
|
|
|
|
|
|
|
|
14
|
3
|
|
|
|
|
39
|
$self->{code} = $code; |
15
|
|
|
|
|
|
|
} |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
sub descend |
18
|
|
|
|
|
|
|
{ |
19
|
3
|
|
|
3
|
0
|
4
|
my $self = shift; |
20
|
3
|
|
|
|
|
5
|
my $got = shift; |
21
|
|
|
|
|
|
|
|
22
|
3
|
|
|
|
|
4
|
my ($ok, $diag) = &{$self->{code}}($got); |
|
3
|
|
|
|
|
9
|
|
23
|
|
|
|
|
|
|
|
24
|
3
|
|
|
|
|
38
|
$self->data->{diag} = $diag; |
25
|
|
|
|
|
|
|
|
26
|
3
|
|
|
|
|
11
|
return $ok; |
27
|
|
|
|
|
|
|
} |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
sub diagnostics |
30
|
|
|
|
|
|
|
{ |
31
|
2
|
|
|
2
|
0
|
4
|
my $self = shift; |
32
|
2
|
|
|
|
|
3
|
my ($where, $last) = @_; |
33
|
|
|
|
|
|
|
|
34
|
2
|
|
|
|
|
4
|
my $error = $last->{diag}; |
35
|
2
|
|
|
|
|
6
|
my $data = Test::Deep::render_val($last->{got}); |
36
|
2
|
|
|
|
|
4
|
my $diag = <
|
37
|
|
|
|
|
|
|
Ran coderef at $where on |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
$data |
40
|
|
|
|
|
|
|
EOM |
41
|
2
|
100
|
|
|
|
16
|
if (defined($error)) |
42
|
|
|
|
|
|
|
{ |
43
|
1
|
|
|
|
|
4
|
$diag .= <
|
44
|
|
|
|
|
|
|
and it said |
45
|
|
|
|
|
|
|
$error |
46
|
|
|
|
|
|
|
EOM |
47
|
|
|
|
|
|
|
} |
48
|
|
|
|
|
|
|
else |
49
|
|
|
|
|
|
|
{ |
50
|
1
|
|
|
|
|
2
|
$diag .= <
|
51
|
|
|
|
|
|
|
it failed but it didn't say why. |
52
|
|
|
|
|
|
|
EOM |
53
|
|
|
|
|
|
|
} |
54
|
|
|
|
|
|
|
|
55
|
2
|
|
|
|
|
7
|
return $diag; |
56
|
|
|
|
|
|
|
} |
57
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
1; |
59
|
|
|
|
|
|
|
|
60
|
|
|
|
|
|
|
__END__ |