File Coverage

blib/lib/CatalystX/RequestModel/Utils/InvalidJSONForValue.pm
Criterion Covered Total %
statement 3 7 42.8
branch n/a
condition n/a
subroutine 1 3 33.3
pod 0 2 0.0
total 4 12 33.3


line stmt bran cond sub pod time code
1             package CatalystX::RequestModel::Utils::InvalidJSONForValue;
2            
3 6     6   44 use Moose;
  6         21  
  6         54  
4             with 'CatalystX::Utils::DoesHttpException';
5            
6             has 'param' => (is=>'ro', required=>1);
7             has 'parsing_error' => (is=>'ro', required=>1);
8              
9 0     0 0   sub status_code { 400 }
10 0     0 0   sub error { "JSON decode error for parameter '@{[ $_[0]->param]}': @{[ $_[0]->parsing_error]}" }
  0            
  0            
11              
12             __PACKAGE__->meta->make_immutable;