summaryrefslogtreecommitdiff
path: root/t/bugs/subclass_use_base_bug.t
diff options
context:
space:
mode:
Diffstat (limited to 't/bugs/subclass_use_base_bug.t')
-rw-r--r--t/bugs/subclass_use_base_bug.t28
1 files changed, 28 insertions, 0 deletions
diff --git a/t/bugs/subclass_use_base_bug.t b/t/bugs/subclass_use_base_bug.t
new file mode 100644
index 0000000..9a4521c
--- /dev/null
+++ b/t/bugs/subclass_use_base_bug.t
@@ -0,0 +1,28 @@
+use strict;
+use warnings;
+
+use Test::More;
+
+=pod
+
+This just makes sure that the Bar gets
+a metaclass initialized for it correctly.
+
+=cut
+
+{
+ package Foo;
+ use Moose;
+
+ package Bar;
+ use strict;
+ use warnings;
+
+ use parent -norequire => 'Foo';
+}
+
+my $bar = Bar->new;
+isa_ok($bar, 'Bar');
+isa_ok($bar, 'Foo');
+
+done_testing;