Commit | Line | Data |
---|---|---|
977a86ba | 1 | #!/usr/bin/perl |
2 | ||
3 | use strict; | |
4 | use warnings; | |
5 | ||
a28e50e4 | 6 | use Test::More; |
be0ed157 | 7 | use Test::Fatal; |
977a86ba | 8 | |
7ff56534 | 9 | |
977a86ba | 10 | { |
11 | package My::Role; | |
12 | use Moose::Role; | |
13 | } | |
14 | { | |
15 | package My::Class; | |
16 | use Moose; | |
d03bd989 | 17 | |
be0ed157 | 18 | ::like ::exception { |
977a86ba | 19 | extends 'My::Role'; |
be0ed157 | 20 | }, qr/You cannot inherit from a Moose Role \(My\:\:Role\)/, |
977a86ba | 21 | '... this croaks correctly'; |
22 | } | |
a28e50e4 | 23 | |
24 | done_testing; |