line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
1
|
|
|
1
|
|
5
|
#line 1 |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
33
|
|
2
|
1
|
|
|
1
|
|
4
|
use strict; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
26
|
|
3
|
|
|
|
|
|
|
use warnings; |
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
package Test::Deep::HashElements; |
6
|
1
|
|
|
1
|
|
6
|
|
|
1
|
|
|
|
|
4
|
|
|
1
|
|
|
|
|
8
|
|
7
|
|
|
|
|
|
|
use Test::Deep::Ref; |
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
sub init |
10
|
44
|
|
|
44
|
0
|
58
|
{ |
11
|
|
|
|
|
|
|
my $self = shift; |
12
|
44
|
|
|
|
|
58
|
|
13
|
|
|
|
|
|
|
my $val = shift; |
14
|
44
|
|
|
|
|
216
|
|
15
|
|
|
|
|
|
|
$self->{val} = $val; |
16
|
|
|
|
|
|
|
} |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
sub descend |
19
|
44
|
|
|
44
|
0
|
70
|
{ |
20
|
|
|
|
|
|
|
my $self = shift; |
21
|
44
|
|
|
|
|
57
|
|
22
|
|
|
|
|
|
|
my $got = shift; |
23
|
44
|
|
|
|
|
63
|
|
24
|
|
|
|
|
|
|
my $exp = $self->{val}; |
25
|
44
|
|
|
|
|
111
|
|
26
|
|
|
|
|
|
|
my $data = $self->data; |
27
|
44
|
|
|
|
|
126
|
|
28
|
|
|
|
|
|
|
my $master = $self->getMaster($got, $exp); |
29
|
44
|
|
|
|
|
123
|
|
30
|
|
|
|
|
|
|
foreach my $key (keys %$master) |
31
|
84
|
|
|
|
|
150
|
{ |
32
|
|
|
|
|
|
|
$data->{index} = $key; |
33
|
84
|
50
|
|
|
|
207
|
|
34
|
84
|
50
|
|
|
|
159
|
my $got_elem = exists $got->{$key} ? $got->{$key} : $Test::Deep::DNE; |
35
|
|
|
|
|
|
|
my $exp_elem = exists $exp->{$key} ? $exp->{$key} : $Test::Deep::DNE; |
36
|
84
|
50
|
|
|
|
194
|
|
37
|
|
|
|
|
|
|
next if Test::Deep::descend($got_elem, $exp_elem); |
38
|
0
|
|
|
|
|
0
|
|
39
|
|
|
|
|
|
|
return 0; |
40
|
|
|
|
|
|
|
} |
41
|
44
|
|
|
|
|
152
|
|
42
|
|
|
|
|
|
|
return 1; |
43
|
|
|
|
|
|
|
} |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
sub getMaster |
46
|
44
|
|
|
44
|
0
|
49
|
{ |
47
|
|
|
|
|
|
|
my $self = shift; |
48
|
44
|
|
|
|
|
61
|
|
49
|
|
|
|
|
|
|
my ($got, $exp) = @_; |
50
|
44
|
50
|
|
|
|
123
|
|
51
|
|
|
|
|
|
|
return keys %$got > keys %$exp ? $got : $exp; |
52
|
|
|
|
|
|
|
} |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
sub render_stack |
55
|
0
|
|
|
0
|
0
|
|
{ |
56
|
0
|
|
|
|
|
|
my $self = shift; |
57
|
0
|
0
|
|
|
|
|
my ($var, $data) = @_; |
58
|
0
|
|
|
|
|
|
$var .= "->" unless $Test::Deep::Stack->incArrow; |
59
|
|
|
|
|
|
|
$var .= '{"'.quotemeta($data->{index}).'"}'; |
60
|
0
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
return $var; |
62
|
|
|
|
|
|
|
} |
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
sub reset_arrow |
65
|
0
|
|
|
0
|
0
|
|
{ |
66
|
|
|
|
|
|
|
return 0; |
67
|
|
|
|
|
|
|
} |
68
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
package Test::Deep::SuperHashElements; |
70
|
1
|
|
|
1
|
|
7
|
|
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
11
|
|
71
|
|
|
|
|
|
|
use base 'Test::Deep::HashElements'; |
72
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
sub getMaster |
74
|
0
|
|
|
0
|
|
|
{ |
75
|
|
|
|
|
|
|
my $self = shift; |
76
|
0
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
my ($got, $exp) = @_; |
78
|
0
|
|
|
|
|
|
|
79
|
|
|
|
|
|
|
return $exp; |
80
|
|
|
|
|
|
|
} |
81
|
|
|
|
|
|
|
|
82
|
|
|
|
|
|
|
package Test::Deep::SubHashElements; |
83
|
1
|
|
|
1
|
|
6
|
|
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
5
|
|
84
|
|
|
|
|
|
|
use base 'Test::Deep::HashElements'; |
85
|
|
|
|
|
|
|
|
86
|
|
|
|
|
|
|
sub getMaster |
87
|
0
|
|
|
0
|
|
|
{ |
88
|
|
|
|
|
|
|
my $self = shift; |
89
|
0
|
|
|
|
|
|
|
90
|
|
|
|
|
|
|
my ($got, $exp) = @_; |
91
|
0
|
|
|
|
|
|
|
92
|
|
|
|
|
|
|
return $got; |
93
|
|
|
|
|
|
|
} |
94
|
|
|
|
|
|
|
|
95
|
|
|
|
|
|
|
1; |