File Coverage

blib/lib/Articulate/Authorisation/AlwaysAllow.pm
Criterion Covered Total %
statement 12 12 100.0
branch n/a
condition n/a
subroutine 4 4 100.0
pod 1 1 100.0
total 17 17 100.0


line stmt bran cond sub pod time code
1             package Articulate::Authorisation::AlwaysAllow;
2 7     7   27691 use strict;
  7         13  
  7         262  
3 7     7   34 use warnings;
  7         10  
  7         170  
4              
5 7     7   726 use Moo;
  7         16417  
  7         34  
6              
7             =head1 NAME
8              
9             Articulate::Authorisation::AlwaysAllow - don't use this in production
10              
11             =cut
12              
13             =head1 CONFIGURATION
14              
15             Put this in your C, NOT in your C or your
16             C. You have been warned.
17              
18             components:
19             authorisation:
20             Articulate::Authorisation:
21             rules:
22             - Articulate::Authorisation::AlwaysAllow
23              
24             There's nothing else to configure, the answer is always yes.
25              
26             =head1 METHODS
27              
28             =head3 new
29              
30             Does what all good C methods do, nothing more.
31              
32             =head3 permitted
33              
34             Handles all the complex business logic required to ensure that the
35             request is always authorised.
36              
37             So don't use this in production.
38              
39             =cut
40              
41             sub permitted {
42 5     5 1 20 my $self = shift;
43 5         11 my $permission = shift;
44 5         29 $permission->grant('Anything is possible!');
45             }
46              
47             =head1 BUGS
48              
49             Don't come crying to me if you use this in production.
50              
51             =cut
52              
53             1;