File Coverage

blib/lib/Mite/App/Command/init.pm.mite.pm
Criterion Covered Total %
statement 38 53 71.7
branch 0 8 0.0
condition 0 9 0.0
subroutine 10 19 52.6
pod 0 2 0.0
total 48 91 52.7


line stmt bran cond sub pod time code
1             {
2              
3             package Mite::App::Command::init;
4 16     16   131 use strict;
  16         52  
  16         583  
5 16     16   98 use warnings;
  16         59  
  16         609  
6 16     16   121 no warnings qw( once void );
  16         48  
  16         2344  
7              
8             our $USES_MITE = "Mite::Class";
9             our $MITE_SHIM = "Mite::Shim";
10             our $MITE_VERSION = "0.011000";
11              
12             # Mite keywords
13             BEGIN {
14 16     16   97 my ( $SHIM, $CALLER ) =
15             ( "Mite::Shim", "Mite::App::Command::init" );
16             (
17             *after, *around, *before, *extends, *field,
18             *has, *param, *signature_for, *with
19             )
20 16         51 = do {
21              
22             package Mite::Shim;
23 16     16   134 no warnings 'redefine';
  16         41  
  16         3919  
24             (
25 0     0   0 sub { $SHIM->HANDLE_after( $CALLER, "class", @_ ) },
26 16     16   114 sub { $SHIM->HANDLE_around( $CALLER, "class", @_ ) },
27 0     0   0 sub { $SHIM->HANDLE_before( $CALLER, "class", @_ ) },
28       16     sub { },
29 0     0   0 sub { $SHIM->HANDLE_has( $CALLER, field => @_ ) },
30 0     0   0 sub { $SHIM->HANDLE_has( $CALLER, has => @_ ) },
31 0     0   0 sub { $SHIM->HANDLE_has( $CALLER, param => @_ ) },
32 0     0   0 sub { $SHIM->HANDLE_signature_for( $CALLER, "class", @_ ) },
33 0     0   0 sub { $SHIM->HANDLE_with( $CALLER, @_ ) },
34 16         3306 );
35             };
36             }
37              
38             # Mite imports
39             BEGIN {
40 16     16   135 require Scalar::Util;
41 16         64 *STRICT = \&Mite::Shim::STRICT;
42 16         62 *bare = \&Mite::Shim::bare;
43 16         68 *blessed = \&Scalar::Util::blessed;
44 16         53 *carp = \&Mite::Shim::carp;
45 16         67 *confess = \&Mite::Shim::confess;
46 16         49 *croak = \&Mite::Shim::croak;
47 16         36 *false = \&Mite::Shim::false;
48 16         47 *guard = \&Mite::Shim::guard;
49 16         36 *lazy = \&Mite::Shim::lazy;
50 16         45 *lock = \&Mite::Shim::lock;
51 16         32 *ro = \&Mite::Shim::ro;
52 16         31 *rw = \&Mite::Shim::rw;
53 16         44 *rwp = \&Mite::Shim::rwp;
54 16         62 *true = \&Mite::Shim::true;
55 16         819 *unlock = \&Mite::Shim::unlock;
56             }
57              
58             BEGIN {
59 16     16   830 require Mite::App::Command;
60              
61 16     16   121 use mro 'c3';
  16         41  
  16         149  
62 16         46 our @ISA;
63 16         3522 push @ISA, "Mite::App::Command";
64             }
65              
66             # See UNIVERSAL
67             sub DOES {
68 0     0 0   my ( $self, $role ) = @_;
69 0           our %DOES;
70 0 0         return $DOES{$role} if exists $DOES{$role};
71 0 0         return 1 if $role eq __PACKAGE__;
72 0 0 0       if ( $INC{'Moose/Util.pm'}
      0        
73             and my $meta = Moose::Util::find_meta( ref $self or $self ) )
74             {
75 0 0 0       $meta->can('does_role') and $meta->does_role($role) and return 1;
76             }
77 0           return $self->SUPER::DOES($role);
78             }
79              
80             # Alias for Moose/Moo-compatibility
81             sub does {
82 0     0 0   shift->DOES(@_);
83             }
84              
85             1;
86             }