File Coverage

blib/lib/Moose/Exception/ClassDoesTheExcludedRole.pm
Criterion Covered Total %
statement 7 7 100.0
branch n/a
condition n/a
subroutine 2 2 100.0
pod n/a
total 9 9 100.0


line stmt bran cond sub pod time code
1             package Moose::Exception::ClassDoesTheExcludedRole;
2             our $VERSION = '2.2205';
3              
4 1     1   673 use Moose;
  1         3  
  1         10  
5             extends 'Moose::Exception';
6             with 'Moose::Exception::Role::Role', 'Moose::Exception::Role::Class';
7              
8             has 'excluded_role_name' => (
9             is => 'ro',
10             isa => 'Str',
11             required => 1
12             );
13              
14             sub _build_message {
15 1     1   2 my $self = shift;
16 1         34 my $excluded_role_name = $self->excluded_role_name;
17 1         30 my $class_name = $self->class_name;
18 1         29 return "The class $class_name does the excluded role '$excluded_role_name'";
19             }
20              
21             __PACKAGE__->meta->make_immutable;
22             1;