Mojito/Auth.pm

filter: Statementstmt 81.8% 18 / 22 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 83.3% 5 / 6 Podpod 0.0% 0 / 1 totaltotal 79.3% 23 / 29 CC 1 SCAR 1.5
CC
1
Cov
82%
BUILD
2.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.2
« Mojito/Template/Role/CSS.pm ↑ Summary Mojito/Collection/CRUD.pm »
1 4 ▶use strictures 1;
Subroutine BEGIN: called CC=1 SCAR=0.0
2 package Mojito::Auth;
3 4 $Mojito::Auth::VERSION = '0.25';
4 4 ▶use Mojito::Auth::Mongo;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 4 ▶use Mojito::Auth::Deep;
Subroutine BEGIN: called CC=1 SCAR=0.0
6 4 ▶use Mojito::Auth::Elasticsearch;
Subroutine BEGIN: called CC=1 SCAR=0.0
7 4 ▶use Moo;
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 =head1 Name
10  
11 Mojito::Auth - authentication delegator class
12  
13 =cut
14  
15 4 has 'auth' => (
16 is => 'ro',
17 lazy => 1,
18 writer => '_set_auth',
19 handles => [ qw( digest_authen_cb _secret get_user add_user remove_user username realm password clear_db_name db_name) ],
20 );
21  
22 0 ▶sub BUILD {
Subroutine BUILD: not called CC=1 SCAR=6.9
Pod undocumented
23 0 my ($self, $constructor_args_href) = @_;
24
25 # Determine the document store backend from the configuration
26 0 my $doc_storage = ucfirst lc $constructor_args_href->{config}->{document_storage};
27 0 my $delegatee = __PACKAGE__ . '::' . $doc_storage;
28 0 $self->_set_auth($delegatee->new($constructor_args_href));
29 }
30  
31 4 1
« Mojito/Template/Role/CSS.pm ↑ Summary Mojito/Collection/CRUD.pm »