File Coverage

blib/lib/WWW/AUR/UserAgent.pm
Criterion Covered Total %
statement 17 17 100.0
branch 1 2 50.0
condition n/a
subroutine 6 6 100.0
pod 1 2 50.0
total 25 27 92.5


line stmt bran cond sub pod time code
1             package WWW::AUR::UserAgent;
2              
3 9     9   53 use warnings 'FATAL' => 'all';
  9         22  
  9         423  
4 9     9   48 use strict;
  9         18  
  9         433  
5              
6 9     9   10400 use LWP::UserAgent qw();
  9         548181  
  9         241  
7 9     9   97 use WWW::AUR qw();
  9         19  
  9         1311  
8              
9             our @ISA = qw(LWP::UserAgent);
10              
11             sub new
12             {
13 126     126 1 364 my $class = shift;
14              
15 126         1303 $class->SUPER::new( 'agent' => "WWW::AUR/v$WWW::AUR::VERSION", @_ );
16             }
17              
18             #---CLASS METHOD---
19             sub InitTLS
20             {
21 115 50   115 0 243 eval { require LWP::Protocol::https; 1 } or
  115         8568  
  115         1812502  
22             die "failed to load LWP::Protocol::https, error:\n$@\n"
23             . "(ensure that LWP::Protocol::https is installed)\n"
24             }
25              
26             1;