Regenerate test files
[gitmo/Mouse.git] / t / 030_roles / 041_empty_method_modifiers_meta_bug.t
1 #!/usr/bin/perl
2 # This is automatically generated by author/import-moose-test.pl.
3 # DO NOT EDIT THIS FILE. ANY CHANGES WILL BE LOST!!!
4 use t::lib::MooseCompat;
5 use strict;
6 use warnings;
7
8 use Test::More;
9
10 # test role and class
11 package SomeRole;
12 use Mouse::Role;
13
14 requires 'foo';
15
16 package SomeClass;
17 use Mouse;
18 has 'foo' => (is => 'rw');
19 with 'SomeRole';
20
21 package main;
22
23 #my $c = SomeClass->new;
24 #isa_ok( $c, 'SomeClass');
25
26 for my $modifier_type (qw[ before around after ]) {
27     my $get_func = "get_${modifier_type}_method_modifiers";
28     my @mms = eval{ SomeRole->meta->$get_func('foo') };
29     is($@, '', "$get_func for no method mods does not die");
30     is(scalar(@mms),0,'is an empty list');
31 }
32
33 done_testing;