Open/TypeDef.pm

filter: Statementstmt 95.6% 44 / 46 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 86.6% 13 / 15 Podpod n/a totaltotal 93.4% 57 / 61 CC 1 SCAR 0.2
CC
1
Cov
96%
__ANON__
1.1
__ANON__
1.1
BEGIN
1.0
CRAP 1.0
« Open.pm ↑ Summary Open/Article.pm »
1 # -*- cperl; cperl-indent-level: 4 -*-
2 # Copyright (C) 2011-2021, Roland van Ipenburg
3 package WWW::NOS::Open::TypeDef v1.0.5;
4 4 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 4 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
6  
7 4 ▶use utf8;
Subroutine BEGIN: called CC=1 SCAR=0.0
8 4 ▶use 5.014000;
Subroutine BEGIN: called CC=1 SCAR=0.0
9  
10 4 ▶use DateTime;
Subroutine BEGIN: called CC=1 SCAR=0.0
11 4 ▶use Date::Parse;
Subroutine BEGIN: called CC=1 SCAR=0.0
12 4 ▶use Moose qw/around has with/;
Subroutine BEGIN: called CC=1 SCAR=0.0
13 4 ▶use Moose::Util::TypeConstraints qw/as coerce from where subtype via/;
Subroutine BEGIN: called CC=1 SCAR=0.0
14 4 ▶use MooseX::Types '-declare' => [qw(NOSURI NOSDateTime)];
Subroutine BEGIN: called CC=1 SCAR=0.0
15 4 ▶use MooseX::Types::Moose qw/Str/;
Subroutine BEGIN: called CC=1 SCAR=0.0
16 4 ▶use URI;
Subroutine BEGIN: called CC=1 SCAR=0.0
17 4 ▶use namespace::autoclean '-also' => qr/^__/sxm;
Subroutine BEGIN: called CC=1 SCAR=0.0
18  
19 ## no critic qw(ProhibitCallsToUndeclaredSubs)
20 4 class_type NOSURI, { 'class' => 'URI' };
21 0 ▶coerce NOSURI, from Str, via { URI->new($_) };
Subroutine __ANON__: not called CC=1 SCAR=1.2
22  
23 4 class_type NOSDateTime, { 'class' => 'DateTime' };
24 coerce NOSDateTime,
25 ## use critic
26 from Str,
27 0 ▶ via { DateTime->from_epoch( 'epoch' => Date::Parse::str2time($_) ) };
Subroutine __ANON__: not called CC=1 SCAR=1.2
28  
29 4 ▶no Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
30  
31 4 __PACKAGE__->meta->make_immutable;
32  
33 4 1;
34  
35 __END__
« Open.pm ↑ Summary Open/Article.pm »