| line |
true |
false |
branch |
|
21
|
5 |
1 |
if exists $INC{$mod_pm} |
|
31
|
0 |
6 |
if ($self eq 'Module::Patch') { } |
|
35
|
0 |
0 |
unless grep {$_ eq $exp;} @EXPORT_OK |
|
43
|
0 |
6 |
if (exists $opts{'-load_target'}) |
|
49
|
1 |
5 |
if (exists $opts{'-force'}) |
|
55
|
0 |
6 |
if (exists $opts{'-warn_target_loaded'}) |
|
62
|
0 |
6 |
if ${"${self}::handles";} |
|
64
|
3 |
3 |
unless (${"${self}::patch_data_cached";}) |
|
68
|
0 |
6 |
unless my $pdata = ${"${self}::patch_data_cached";} |
|
72
|
0 |
6 |
if ($v == 1 or $v == 2) { } |
|
|
6 |
0 |
elsif ($v == 3) { } |
|
74
|
0 |
0 |
if ($v == 1) { } |
|
|
0 |
0 |
elsif ($v == 2) { } |
|
92
|
0 |
6 |
unless $target =~ s/(?<=\w)::[Pp]atch::\w+$// |
|
96
|
5 |
1 |
if (is_loaded($target)) { } |
|
97
|
0 |
5 |
unless ($loaded_by_us{$target}) |
|
98
|
0 |
0 |
if ($load and $warn) |
|
106
|
1 |
0 |
if ($load) { } |
|
108
|
0 |
1 |
if $@ |
|
111
|
0 |
0 |
if ($warn) |
|
124
|
0 |
6 |
unless $k =~ /\A-/ |
|
127
|
1 |
5 |
if (exists $opts{$k}) |
|
133
|
1 |
5 |
if (keys %opts) |
|
137
|
0 |
5 |
if ($pdata->{'after_read_config'}) |
|
141
|
0 |
5 |
if ($pdata->{'before_patch'}) |
|
150
|
0 |
4 |
if ($pdata->{'after_patch'}) |
|
160
|
0 |
4 |
if ($self eq 'Module::Patch') { } |
|
163
|
0 |
4 |
unless my $pdata = ${"${self}::patch_data_cached";} |
|
166
|
0 |
4 |
if ($pdata->{'before_unpatch'}) |
|
175
|
0 |
4 |
if ($pdata->{'after_unpatch'}) |
|
191
|
0 |
5 |
ref $package0 eq 'ARRAY' ? : |
|
192
|
0 |
5 |
unless package_exists($target) |
|
201
|
7 |
0 |
$opts->{'patch_module'} ? : |
|
203
|
0 |
7 |
unless $act |
|
204
|
0 |
7 |
unless $act =~ /\A(wrap|add|replace|add_or_replace|delete)\z/ |
|
206
|
0 |
7 |
if ($act eq 'delete') { } |
|
207
|
0 |
0 |
if $pspec->{'code'} |
|
210
|
0 |
7 |
unless $pspec->{'code'} |
|
214
|
0 |
7 |
ref $pspec->{'sub_name'} eq 'ARRAY' ? : |
|
216
|
0 |
7 |
if $_ eq ':all' |
|
217
|
0 |
7 |
if $_ eq ':private' |
|
218
|
0 |
7 |
if $_ eq ':public' |
|
219
|
0 |
7 |
if /^:/ |
|
224
|
0 |
7 |
if (ref $sub_name eq 'Regexp') { } |
|
225
|
0 |
0 |
unless ($target_subs) |
|
229
|
0 |
0 |
if not $_ =~ ~@s and $_ =~ /$sub_name/ |
|
236
|
5 |
2 |
unless (not defined $pspec->{'mod_version'} or $pspec->{'mod_version'} eq ':all') |
|
238
|
0 |
5 |
unless defined $target_version and length $target_version |
|
242
|
2 |
3 |
ref $mod_versions eq 'ARRAY' ? : |
|
245
|
0 |
7 |
if $_ eq ':all' |
|
246
|
0 |
7 |
if /^:/ |
|
250
|
2 |
3 |
unless (grep {ref $_ eq 'Regexp' ? $target_version =~ /$_/ : $target_version eq $_;} @$mod_versions) |
|
251
|
0 |
7 |
ref $_ eq 'Regexp' ? : |
|
256
|
1 |
1 |
$opts->{'force'} ? : |
|
257
|
1 |
1 |
unless $opts->{'force'} |