File Coverage

lib/BalanceOfPower/Commands/BoostProduction.pm
Criterion Covered Total %
statement 11 11 100.0
branch 2 2 100.0
condition n/a
subroutine 3 3 100.0
pod 0 1 0.0
total 16 17 94.1


line stmt bran cond sub pod time code
1             package BalanceOfPower::Commands::BoostProduction;
2             $BalanceOfPower::Commands::BoostProduction::VERSION = '0.400105';
3 13     13   41 use Moo;
  13         18  
  13         50  
4              
5 13     13   2372 use BalanceOfPower::Constants ":all";
  13         18  
  13         5805  
6              
7             extends 'BalanceOfPower::Commands::NoArgs';
8              
9             sub IA
10             {
11 21     21 0 23 my $self = shift;
12 21         42 my $nation = $self->get_nation();
13 21 100       50 if($nation->production < EMERGENCY_PRODUCTION_LIMIT)
14             {
15 5         8 return "BOOST PRODUCTION"
16             }
17             else
18             {
19 16         27 return undef;
20             }
21             }
22              
23             1;