Branch Coverage

blib/lib/InlineX/CPP2XS.pm
Criterion Covered Total %
branch 161 214 75.2


line true false branch
28 0 19 if ($@ or $Inline::CPP::VERSION < 0.39)
37 18 1 if (@_)
38 6 12 if (ref $_[0] eq 'HASH') { }
40 1 5 if (@_)
42 1 6 unless _check_config_keys($_)
47 11 6 if (@_)
48 1 10 if (ref $_[0] ne 'HASH')
51 0 62 unless _check_config_keys($_)
54 1 15 unless (-d $build_dir)
58 6 9 $config_options->{'AUTOWRAP'} ? :
62 1 2 if (exists $config_options->{'CODE'} and exists $config_options->{'SRC_LOCATION'})
66 0 1 if (exists $config_options->{'BOOT'} and exists $config_options->{'BOOT_F'})
70 2 12 if (exists $config_options->{'CODE'}) { }
5 7 elsif (exists $config_options->{'SRC_LOCATION'}) { }
72 0 2 if ($code =~ /inline_stack_vars/i)
75 1 4 unless open RD, '<', $config_options->{'SRC_LOCATION'}
78 0 454 if ($_ =~ /inline_stack_vars/i)
80 0 4 unless close RD
83 0 7 unless open RD, '<', "src/$modfname.cpp"
86 2 61 if ($_ =~ /inline_stack_vars/i)
88 0 7 unless close RD
136 1 12 if (exists $config_options->{'BUILD_NOISY'})
138 1 12 if ($config_options->{'DIST'})
145 6 7 if ($config_options->{'AUTOWRAP'})
147 1 12 if ($config_options->{'BOOT'})
149 0 13 if ($config_options->{'BOOT_F'})
151 0 0 unless open RD, '<', $config_options->{'BOOT_F'}
154 0 0 if ($_ =~ /inline_stack_vars/i)
156 0 0 unless close RD
162 1 12 if ($config_options->{'MAKE'})
164 7 6 if (exists $config_options->{'TYPEMAPS'}) { }
165 5 2 if (ref $config_options->{'TYPEMAPS'} eq 'ARRAY') { }
167 1 4 unless -f $_
174 0 2 unless -f $_
186 1 11 if ($config_options->{'PREFIX'})
192 1 11 if ($config_options->{'LIBS'})
195 1 0 if (ref $o->{'ILSM'}{'MAKEFILE'}{'LIBS'} eq 'ARRAY') { }
203 1 0 if (ref $config_options->{'LIBS'} eq 'ARRAY') { }
214 2 10 if ($config_options->{'PRE_HEAD'})
218 1 1 if (not -f $v) { }
223 0 1 unless open RD, '<', $v
225 0 1 unless close RD
231 6 6 if ($config_options->{'AUTO_INCLUDE'})
233 1 11 if ($config_options->{'CC'})
235 1 11 if ($config_options->{'CCFLAGS'})
237 0 12 if ($config_options->{'CCFLAGSEX'})
240 6 6 if (exists $config_options->{'INC'}) { }
241 0 6 if (ref $config_options->{'INC'} eq 'ARRAY') { }
248 1 11 if ($config_options->{'LD'})
250 1 11 if ($config_options->{'PREREQ_PM'})
252 1 11 if ($config_options->{'LDDLFLAGS'})
256 1 11 if ($config_options->{'MAKE'})
258 1 11 if ($config_options->{'MYEXTLIB'})
260 1 11 if ($config_options->{'OPTIMIZE'})
262 0 12 if ($config_options->{'USING'})
264 0 0 if (ref $val eq 'ARRAY') { }
273 5 7 unless ($need_inline_h)
278 1 11 uc $config_options->{'WRITE_MAKEFILE_PL'} eq 'P' ? :
283 4 8 if ($config_options->{'WRITE_MAKEFILE_PL'})
286 4 0 if ($config_options->{'VERSION'}) { }
290 1 3 if (uc $config_options->{'WRITE_MAKEFILE_PL'} eq 'P')
295 4 8 if ($config_options->{'WRITE_PM'})
296 4 0 if ($config_options->{'VERSION'}) { }
304 2 10 if ($config_options->{'MANIF'})
308 1 11 if ($config_options->{'T'})
328 1 11 if ($portable)
331 0 1 unless open WRA, '>', "$build_dir/auto_include.in"
333 2 16 if $l =~ /__INLINE_CPP_STANDARD_HEADERS/ or $l =~ /__INLINE_CPP_NAMESPACE_STD/
336 0 1 unless close WRA
344 1 11 if $portable
346 7 5 if ($need_inline_headers)
357 68 912 if $_ eq $_[0]
371 2 2 if ($config_options->{'USE'})
373 0 2 if ref $config_options->{'USE'} ne 'ARRAY'
377 0 4 unless open WR, '>', $o->{'API'}{'build_dir'} . '/' . $o->{'API'}{'modfname'} . '.pm'
392 3 1 if (not $config_options->{'EXPORT_ALL'}) { }
399 4 4 if ($_ =~ /^_/ and not $_ =~ /^__/)
401 0 4 if ($length + $l > $max)
405 1 3 if ($length == $offset) { }
413 1 3 if (not $config_options->{'EXPORT_OK_ALL'} || $config_options->{'EXPORT_TAGS_ALL'}) { }
420 20 6 if ($_ =~ /^_/ and not $_ =~ /^__/)
422 0 6 if ($length + $l > $max)
426 3 3 if ($length == $offset) { }
434 1 3 if ($config_options->{'EXPORT_TAGS_ALL'})
438 4 4 if ($_ =~ /^_/ and not $_ =~ /^__/)
440 0 4 if ($length + $l > $max)
444 1 3 if ($length == $offset) { }
454 0 4 unless close WR
466 0 1 unless rename "$bd/Makefile.PL", "$bd/Makefile.PL_first"
480 0 1 unless open WRT, '>', "$bd/ilcpptest.cpp"
482 0 1 unless close WRT
485 0 1 unless open RD, '<', "$bd/Makefile.PL_first"
486 0 1 unless open WR, '>', "$bd/Makefile.PL"
633 0 19 if ($_ =~ /'LIBS' => '/)
639 1 18 if ($_ =~ /'CC' =>/)
643 0 1 unless close RD
644 0 1 unless close WR
645 0 1 unless unlink "$bd/Makefile.PL_first"
658 0 2 unless open WRM, '>', "$bd/MANIFEST"
660 2 0 if ($c->{'WRITE_PM'})
661 0 2 if ($ih)
663 2 0 if ($c->{'WRITE_MAKEFILE_PL'})
665 1 1 if (uc $c->{'WRITE_MAKEFILE_PL'} eq 'P')
678 0 1 unless (-d $path)
679 0 0 unless (File::Path::make_path($path, {'verbose', 1}))
683 0 1 unless open WRT, '>', "$path/00load.t"
690 0 1 unless close WRT