OpenGbg/Service/Bridge/BridgeOpening.pm

filter: Statementstmt 93.9% 31 / 33 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 80.0% 8 / 10 Podpod n/a totaltotal 90.7% 39 / 43 CC 1 SCAR 1.8
CC
1
Cov
94%
_build_timestamp
2.0
_build_was_open
2.0
BEGIN
1.0
CRAP 1.2
« OpenGbg/Service/TrafficCamera/GetCameraImage.pm ↑ Summary OpenGbg/Service/TrafficCamera/CameraDevice.pm »
1 1 ▶use 5.10.0;
Subroutine BEGIN: called CC=1 SCAR=0.0
2 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
3 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
4  
5 package OpenGbg::Service::Bridge::BridgeOpening;
6  
7 # ABSTRACT: A change in status for Göta Älvbron
8 1 our $AUTHORITY = 'cpan:CSSON'; # AUTHORITY
9 1 our $VERSION = '0.1404';
10  
11 1 ▶use XML::Rabbit;
Subroutine BEGIN: called CC=1 SCAR=0.0
12 1 ▶use DateTime::Format::HTTP;
Subroutine BEGIN: called CC=1 SCAR=0.0
13 1 ▶use MooseX::AttributeShortcuts;
Subroutine BEGIN: called CC=1 SCAR=0.0
14 1 ▶use Types::DateTime qw/DateTime/;
Subroutine BEGIN: called CC=1 SCAR=0.0
15 1 ▶use Types::Standard qw/Bool/;
Subroutine BEGIN: called CC=1 SCAR=0.0
16  
17 1 has_xpath_value _timestamp => './x:TimeStamp';
18  
19 1 has_xpath_value _was_open => './x:Value';
20  
21 1 has timestamp => (
22 is => 'ro',
23 isa => DateTime,
24 lazy => 1,
25 builder => 1,
26 );
27  
28 1 has was_open => (
29 is => 'ro',
30 isa => Bool,
31 lazy => 1,
32 builder => 1,
33 );
34  
35 0 ▶sub _build_timestamp {
Subroutine _build_timestamp: not called CC=1 SCAR=6.9
36 0 return DateTime::Format::HTTP->parse_datetime(shift->_timestamp);
37 }
38 0 ▶sub _build_was_open {
Subroutine _build_was_open: not called CC=1 SCAR=6.9
39 0 return shift->_was_open eq 'true';
40 }
41  
42 1 finalize_class();
43  
44 1 1;
45  
46 __END__
« OpenGbg/Service/TrafficCamera/GetCameraImage.pm ↑ Summary OpenGbg/Service/TrafficCamera/CameraDevice.pm »