line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Test::MasterData::Declare::Compare::RowCustrom; |
2
|
4
|
|
|
4
|
|
73
|
use 5.010001; |
|
4
|
|
|
|
|
17
|
|
3
|
4
|
|
|
4
|
|
26
|
use strict; |
|
4
|
|
|
|
|
11
|
|
|
4
|
|
|
|
|
91
|
|
4
|
4
|
|
|
4
|
|
24
|
use warnings; |
|
4
|
|
|
|
|
10
|
|
|
4
|
|
|
|
|
114
|
|
5
|
4
|
|
|
4
|
|
25
|
use utf8; |
|
4
|
|
|
|
|
9
|
|
|
4
|
|
|
|
|
21
|
|
6
|
|
|
|
|
|
|
|
7
|
4
|
|
|
4
|
|
137
|
use parent "Test2::Compare::Custom"; |
|
4
|
|
|
|
|
12
|
|
|
4
|
|
|
|
|
36
|
|
8
|
|
|
|
|
|
|
|
9
|
4
|
|
|
4
|
|
278
|
use Carp qw/croak/; |
|
4
|
|
|
|
|
10
|
|
|
4
|
|
|
|
|
189
|
|
10
|
4
|
|
|
4
|
|
28
|
use Scalar::Util qw/blessed/; |
|
4
|
|
|
|
|
10
|
|
|
4
|
|
|
|
|
1159
|
|
11
|
|
|
|
|
|
|
|
12
|
6
|
|
|
6
|
|
35
|
sub object_base { "Test::MasterData::Declare::Row" } |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
sub verify { |
15
|
6
|
|
|
6
|
|
168
|
my $self = shift; |
16
|
6
|
|
|
|
|
21
|
my %params = @_; |
17
|
6
|
|
|
|
|
20
|
my ($got, $exists) = @params{qw/got exists/}; |
18
|
|
|
|
|
|
|
|
19
|
6
|
50
|
|
|
|
18
|
return 0 unless $exists; |
20
|
6
|
50
|
|
|
|
14
|
return 0 unless $got; |
21
|
6
|
50
|
|
|
|
18
|
return 0 unless ref($got); |
22
|
6
|
50
|
|
|
|
24
|
return 0 unless blessed($got); |
23
|
6
|
50
|
|
|
|
22
|
return 0 unless $got->isa($self->object_base); |
24
|
|
|
|
|
|
|
|
25
|
6
|
|
|
|
|
28
|
$params{got} = $got->row; |
26
|
6
|
|
|
|
|
38
|
return $self->SUPER::verify(%params); |
27
|
|
|
|
|
|
|
} |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
sub run { |
31
|
6
|
|
|
6
|
|
985
|
my $self = shift; |
32
|
6
|
|
|
|
|
24
|
my %params = @_; |
33
|
6
|
|
|
|
|
15
|
my $got = $params{got}; |
34
|
|
|
|
|
|
|
|
35
|
6
|
|
|
|
|
28
|
$params{got} = $got->row; |
36
|
|
|
|
|
|
|
|
37
|
6
|
|
|
|
|
36
|
my $delta = $self->SUPER::run(@_); |
38
|
6
|
50
|
|
|
|
1579
|
return unless $delta; |
39
|
|
|
|
|
|
|
|
40
|
0
|
|
|
|
|
|
my $ccheck = $self->clone; |
41
|
0
|
|
|
|
|
|
$ccheck->set_file($got->file); |
42
|
0
|
|
|
|
|
|
$ccheck->set_lines([$got->lineno]); |
43
|
0
|
|
|
|
|
|
$delta->set_check($ccheck); |
44
|
0
|
|
|
|
|
|
$delta->set_id(["HASH" => $got->source]); |
45
|
0
|
|
|
|
|
|
$delta->set_got($got->row); |
46
|
0
|
|
|
|
|
|
return $delta; |
47
|
|
|
|
|
|
|
} |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
1; |