File Coverage

lib/Finance/Alpaca/Struct/Quote.pm
Criterion Covered Total %
statement 30 30 100.0
branch n/a
condition n/a
subroutine 10 10 100.0
pod n/a
total 40 40 100.0


line stmt bran cond sub pod time code
1             package Finance::Alpaca::Struct::Quote 0.9902 {
2 1     1   7 use strictures 2;
  1         7  
  1         38  
3 1     1   175 use feature 'signatures';
  1         1  
  1         60  
4 1     1   6 no warnings 'experimental::signatures';
  1         2  
  1         56  
5             #
6 1     1   7 use Type::Library 0.008 -base, -declare => qw[Quote];
  1         16  
  1         6  
7 1     1   473 use Type::Utils qw[class_type from coerce]; # Do not import as()
  1         2  
  1         5  
8 1     1   685 use Types::Standard qw[ArrayRef Int Num Ref Str];
  1         2  
  1         6  
9 1     1   1215 use Types::TypeTiny 0.004 StringLike => { -as => "Stringable" };
  1         31  
  1         7  
10             class_type Quote, { class => __PACKAGE__ };
11             coerce( Quote, from Ref() => __PACKAGE__ . q[->new($_)] );
12             #
13 1     1   359 use Moo;
  1         2  
  1         6  
14 1     1   293 use lib './lib';
  1         11  
  1         9  
15 1     1   143 use Finance::Alpaca::Types;
  1         2  
  1         7  
16             has t => ( is => 'ro', isa => Timestamp, required => 1, coerce => 1 );
17             has ax => ( is => 'ro', isa => Str, required => 1 );
18              
19             has [qw[ap bp]] => ( is => 'ro', isa => Num, required => 1 );
20             has [qw[as bs]] => ( is => 'ro', isa => Int, required => 1 );
21             has c => ( is => 'ro', isa => ArrayRef [Str], required => 1 );
22             has S => ( is => 'ro', isa => Str, predicate => 1 ); # If from stream
23             }
24             1;
25             __END__