YR/TextLocation.pm

filter: Statementstmt 73.6% 14 / 19 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 75.0% 3 / 4 Podpod n/a totaltotal 73.9% 17 / 23 CC 1 SCAR 2.2
CC
1
Cov
74%
_build_url
2.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.2
« YR/Model/WindSpeed.pm ↑ Summary YR/Lang/Symbol.pm »
1 package Weather::YR::TextLocation;
2 3 ▶use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
3 3 ▶use namespace::autoclean;
Subroutine BEGIN: called CC=1 SCAR=0.0
4  
5 3 extends 'Weather::YR::Base';
6  
7 3 ▶use Mojo::URL;
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 3 has 'lang' => (
10 isa => 'Str',
11 is => 'rw',
12 default => 'en',
13 );
14  
15 3 has 'url' => (
16 isa => 'Mojo::URL',
17 is => 'ro',
18 lazy_build => 1,
19 );
20  
21 0 ▶sub _build_url {
Subroutine _build_url: not called CC=1 SCAR=6.9
22 0 my $self = shift;
23  
24 0 my $url = $self->service_url->clone;
25 0 $url->path ( '/weatherapi/textlocation/1.0/' );
26 0 $url->query(
27 latitude => $self->lat,
28 longitude => $self->lon,
29 language => $self->lang,
30 );
31  
32 0 return $url;
33 }
34  
35 3 __PACKAGE__->meta->make_immutable;
36  
37 3 1;
« YR/Model/WindSpeed.pm ↑ Summary YR/Lang/Symbol.pm »