Moose now warns when you try to load it from the main package. Added a
[gitmo/Moose.git] / t / 100_bugs / 016_inheriting_from_roles.t
CommitLineData
977a86ba 1#!/usr/bin/perl
2
3use strict;
4use warnings;
5
7ff56534 6use Test::More tests => 1;
977a86ba 7use Test::Exception;
8
7ff56534 9
977a86ba 10
11{
12 package My::Role;
13 use Moose::Role;
14}
15{
16 package My::Class;
17 use Moose;
18
19 ::throws_ok {
20 extends 'My::Role';
21 } qr/You cannot inherit from a Moose Role \(My\:\:Role\)/,
22 '... this croaks correctly';
23}