CCfnX/ImportBase.pm untested

filter: Statementstmt 0.0% 0 / 22 Branchbran 0.0% 0 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 5 Podpod 0.0% 0 / 1 totaltotal 0.0% 0 / 30 CC 2 SCAR 12.0
CC
2
Cov
0%
get_deployer
6.0
BEGIN
2.0
BEGIN
2.0
CRAP 3.3
1 package CCfnX::ImportBase {
2 use Moose;
3 use CCfnX::VirtualDeployment;
4 use CCfnX::PersistentDeployment;
5 use Data::Printer;
6  
7 sub get_deployer {
8 my $self = shift;
9  
10 my @roles;
11 if ($ENV{ CLOUDDEPLOY_PERSIST }) {
12 push @roles, 'CCfnX::PersistentDeployment';
13 } else {
14 warn 'To persist the stack to the database, please activate ENV CLOUDDEPLOY_PERSIST';
15 }
16  
17 my $new_class = Moose::Util::with_traits('CCfnX::VirtualDeployment', @roles);
18  
19 my $deployer = $new_class->new(origin => $self);
20  
21 print "These are your outputs\n";
22 p $deployer->outputs;
23  
24 return $deployer;
25 }
26 }
27  
28 1;