Make Mouse::Util::load_class return the argument class name, which can remove several...
[gitmo/Mouse.git] / xt / 05_dbsub.t
1 #!perl -w
2 BEGIN{ $^P = 0x10 | 0x200 }
3 use Test::More;
4
5 sub DB::DB {}
6
7 {
8     package Foo;
9     use Mouse;
10
11     __PACKAGE__->meta->add_method(bar => sub{ __LINE__ });
12 }
13
14 if(Mouse::Util::MOUSE_XS){
15 is $DB::sub{'Foo::bar'}, sprintf('%s:%d-%d', __FILE__, Foo->bar, Foo->bar),
16     '%DB::sub updated';
17 }
18 else{
19     pass 'under Mouse::PurePerl';
20 }
21
22 done_testing;