File Coverage

blib/lib/HTTP/Throwable/Variant.pm
Criterion Covered Total %
statement 14 15 93.3
branch 1 2 50.0
condition n/a
subroutine 4 4 100.0
pod 0 1 0.0
total 19 22 86.3


line stmt bran cond sub pod time code
1             package HTTP::Throwable::Variant 0.028;
2             our $AUTHORITY = 'cpan:STEVAN';
3              
4 5     5   34 use strict;
  5         11  
  5         139  
5 5     5   29 use warnings;
  5         10  
  5         250  
6              
7             use Package::Variant 1.002000
8 5         35 importing => ['Moo', 'MooX::StrictConstructor'],
9 5     5   2657 subs => [ qw(extends with) ];
  5         36980  
10              
11             sub make_variant {
12 60     60 0 195154 my ($class, $target_package, %arguments) = @_;
13 0         0 extends @{ $arguments{superclasses} }
14 60 50       131 if @{ $arguments{superclasses} };
  60         252  
15 60         118 with @{ $arguments{roles} };
  60         279  
16             }
17              
18             1;
19              
20             =pod
21              
22             =encoding UTF-8
23              
24             =head1 NAME
25              
26             HTTP::Throwable::Variant - a package that constructs Moo-based HTTP::Throwables for you
27              
28             =head1 VERSION
29              
30             version 0.028
31              
32             =head1 OVERVIEW
33              
34             This package is used by L to build
35             exceptions at runtime. The exceptions are L-based, with
36             L applied as well. It takes two arguments:
37             C, an arrayref of classes to extend, and C, an
38             arrayref of roles to compose.
39              
40             =head1 PERL VERSION
41              
42             This library should run on perls released even a long time ago. It should work
43             on any version of perl released in the last five years.
44              
45             Although it may work on older versions of perl, no guarantee is made that the
46             minimum required version will not be increased. The version may be increased
47             for any reason, and there is no promise that patches will be accepted to lower
48             the minimum required perl.
49              
50             =head1 AUTHORS
51              
52             =over 4
53              
54             =item *
55              
56             Stevan Little
57              
58             =item *
59              
60             Ricardo Signes
61              
62             =back
63              
64             =head1 COPYRIGHT AND LICENSE
65              
66             This software is copyright (c) 2011 by Infinity Interactive, Inc.
67              
68             This is free software; you can redistribute it and/or modify it under
69             the same terms as the Perl 5 programming language system itself.
70              
71             =cut
72              
73             __END__