File Coverage

blib/lib/Software/Policies/Security.pm
Criterion Covered Total %
statement 15 24 62.5
branch n/a
condition 0 2 0.0
subroutine 6 8 75.0
pod 3 3 100.0
total 24 37 64.8


line stmt bran cond sub pod time code
1             package Software::Policies::Security;
2              
3 2     2   3734 use strict;
  2         9  
  2         113  
4 2     2   13 use warnings;
  2         4  
  2         120  
5 2     2   36 use 5.010;
  2         8  
6              
7             # ABSTRACT: Create project policy file: Security
8              
9             our $VERSION = '0.002';
10              
11 2     2   14 use Carp;
  2         5  
  2         158  
12 2     2   12 use Module::Load qw( load );
  2         13  
  2         43  
13              
14             sub new {
15 0     0 1 0 my ($class) = @_;
16 0         0 return bless {}, $class;
17             }
18              
19             sub create {
20 0     0 1 0 my ( $self, %args ) = @_;
21 0   0     0 my $class = $args{'class'} // 'Individual';
22 0         0 my $module = __PACKAGE__ . q{::} . $class;
23 0         0 load $module;
24 0         0 my $m = $module->new();
25 0         0 my %r = $m->create(%args);
26 0         0 return \%r;
27             }
28              
29             sub get_available_classes_and_versions {
30             return {
31 1     1 1 11 'Individual' => {
32             versions => {
33             '1' => 1,
34             },
35             formats => {
36             'markdown' => 1,
37             },
38             },
39             };
40             }
41              
42             1;
43              
44             __END__