File Coverage

blib/lib/Weather/YR/Model/Precipitation/Symbol.pm
Criterion Covered Total %
statement 9 11 81.8
branch n/a
condition n/a
subroutine 3 4 75.0
pod n/a
total 12 15 80.0


line stmt bran cond sub pod time code
1             package Weather::YR::Model::Precipitation::Symbol;
2 3     3   21 use Moose;
  3         8  
  3         21  
3 3     3   19673 use namespace::autoclean;
  3         8  
  3         21  
4              
5             extends 'Weather::YR::Model';
6              
7 3     3   2345 use Weather::YR::Lang::Symbol;
  3         11  
  3         484  
8              
9             has 'id' => ( isa => 'Str', is => 'rw', required => 1 );
10             has 'number' => ( isa => 'Int', is => 'rw', required => 1 );
11              
12             has 'text' => ( isa => 'Str', is => 'ro', lazy_build => 1 );
13              
14             sub _build_text {
15 0     0     my $self = shift;
16              
17 0           return Weather::YR::Lang::Symbol->new(
18             number => $self->number,
19             lang => $self->lang,
20             )->text;
21             }
22              
23             __PACKAGE__->meta->make_immutable;
24              
25             1;