new fialing test. yayy
Guillermo Roditi [Fri, 18 Jul 2008 17:48:36 +0000 (17:48 +0000)]
t/100_bugs/018_modifiers_n_changed_superclasses.t [new file with mode: 0644]

diff --git a/t/100_bugs/018_modifiers_n_changed_superclasses.t b/t/100_bugs/018_modifiers_n_changed_superclasses.t
new file mode 100644 (file)
index 0000000..015baf4
--- /dev/null
@@ -0,0 +1,28 @@
+#!/usr/bin/perl
+
+use strict;
+use warnings;
+
+use Test::More tests => 2;
+
+BEGIN {
+    use_ok('Moose');
+}
+
+{
+    package Foo;
+    use Moose;
+    sub foo { 'foo' }
+
+    package Bar;
+    use Moose;
+    sub foo { 'bar' }
+
+    package FooBar;
+    use Moose;
+    extends 'Foo';
+    around foo => sub{ shift->(@_) };
+}
+
+FooBar->meta->superclasses('Bar');
+is(FooBar->foo, 'bar', 'method modified changed along with metaclass');