File Coverage

examples/neo-makemaker/inc/My/NeoDynDeps.pm
Criterion Covered Total %
statement 19 19 100.0
branch n/a
condition n/a
subroutine 6 6 100.0
pod 0 1 0.0
total 25 26 96.1


line stmt bran cond sub pod time code
1 1     1   2433 use 5.006;
  1         3  
2 1     1   4 use strict;
  1         1  
  1         18  
3 1     1   3 use warnings;
  1         1  
  1         38  
4              
5             package inc::My::NeoDynDeps;
6              
7             # ABSTRACT: A new dependency injector thingy
8              
9             # AUTHORITY
10              
11 1     1   3 use Moose qw( with );
  1         1  
  1         6  
12             with 'Dist::Zilla::Role::Plugin';
13 1     1   3586 no Moose;
  1         1  
  1         4  
14             __PACKAGE__->meta->make_immutable;
15              
16             # This is obviously a rediculously tiny and simple big of code
17             # in comparison with the normal shenanigans.
18             sub inject_prelude {
19 2     2 0 3 my ( $self, $event ) = @_;
20 2         59 my $text = $event->prelude;
21 2         3 $text .= <<'EOF';
22             if( 'MSWin32' eq $^OS ) {
23             die "Sorry, Win32 Unsupported";
24             }
25             EOF
26 2         52 $event->prelude($text);
27 2         4 return;
28             }
29              
30             1;
31