Fix tests that I broke with my reformatting
[gitmo/Moose.git] / t / 100_bugs / 025_universal_methods_wrappable.t
CommitLineData
6c13ef0d 1use strict;
2use warnings;
5bf26510 3
4use Test::Exception;
5use Test::More tests => 2;
6
6dabb7f5 7{
5bf26510 8
6dabb7f5 9 package FakeBar;
10 use Moose::Role;
6c13ef0d 11
6dabb7f5 12 around isa => sub {
5bf26510 13 my ( $orig, $self, $v ) = @_;
6dabb7f5 14 return 1 if $v eq 'Bar';
5bf26510 15 return $orig->( $self, $v );
6dabb7f5 16 };
6c13ef0d 17
6c13ef0d 18 package Foo;
19 use Moose;
6c13ef0d 20
a28643a3 21 use Test::More; # for $TODO
6c13ef0d 22
a28643a3 23 local $TODO = 'UNIVERSAL methods should be wrappable';
6c13ef0d 24
a28643a3 25 ::lives_ok { with 'FakeBar' } 'applied role';
26
27 my $foo = Foo->new;
28 ::isa_ok $foo, 'Bar';
6dabb7f5 29}