blib/lib/Dist/Zilla/Plugin/InlineIncluder.pm

filter: Statementstmt 52.1% 12 / 23 Branchbran 0.0% 0 / 4 Conditioncond 0.0% 0 / 3 MC/DCmcdc 0.0% 0 / 2 Subroutinesub 40.0% 2 / 5 Podpod 0.0% 0 / 1 totaltotal 36.8% 14 / 38 CC 5 SCAR 28.5
CC
5
Cov
40%
gather_files
30.0
__ANON__
2.0
__ANON__
2.0
CRAP 17.3
↑ Summary
1 package Dist::Zilla::Plugin::InlineIncluder;
2 1 our $VERSION = '0.02';
3  
4 1 ▶use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 1 extends 'Dist::Zilla::Plugin::ModuleIncluder';
7  
8 has module => (
9 isa => 'ArrayRef[Str]',
10 traits => ['Array'],
11 handles => {
12 modules => 'elements',
13 },
14 0 ▶ default => sub {[qw(
Subroutine __ANON__: not called CC=1 SCAR=6.9
15 Inline
16 Inline::C
17 Inline::MakeMaker
18 )]},
19 1 );
20  
21 has blacklist => (
22 isa => 'ArrayRef[Str]',
23 traits => ['Array'],
24 handles => {
25 blacklisted_modules => 'elements',
26 },
27 0 ▶ default => sub {[qw(
Subroutine __ANON__: not called CC=1 SCAR=6.9
28 XXX
29 Inline::Filters
30 Inline::Struct
31 )]},
32 1 );
33  
34  
35 0 ▶sub gather_files {
Subroutine gather_files: not called CC=5 SCAR=34.0
Pod undocumented
36 0 my $self = shift;
37 0 for my $prefix (qw(.. ../..)) {
38 0 my $inline = "$prefix/inline-pm";
39 0 my $inline_c = "$prefix/inline-c-pm";
40 0 ▶ if (
Branch: 1 branch
BranchTrueFalseTotal
if (-d "$inline/.git" and -d "$inline_c/.git") 0 0 0
Condition0%0/3
-d "$inline/.git" and -d "$inline_c/.git"
!ll&&!rl&&r
000
MC/DC0%0/2
-d "$inline/.git" and -d "$inline_c/.git"
-d "$inline/.git" -d "$inline_c/.git"
Truth table0%0/3
A and B
A= -d "$inline/.git"B= -d "$inline_c/.git"
ABresult
0X0
100
111
41 -d "$inline/.git" and
42 -d "$inline_c/.git"
43 ) {
44 0 ▶ eval "use lib '$inline/lib', '$inline_c/lib'; 1" or die $@;
Branch: 1 branch
BranchTrueFalseTotal
eval "use lib '$inline/lib', '$inline_c/lib'; 1" or die $@ 0 0 0
45 0 $self->SUPER::gather_files(@_);
46 0 return;
47 }
48 }
49 0 die "Inline and Inline-C repos missing or not in right state";
50 }
51  
52 1 __PACKAGE__->meta->make_immutable;
53  
54 1 ▶no Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
55  
56 1 1;
↑ Summary