From: Shawn M Moore Date: Wed, 15 Apr 2009 21:01:28 +0000 (-0400) Subject: Make sure -metaclass works for Moose too X-Git-Tag: 0.75~9 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=95d0736063cf146eda26d79b78bf831ecfb98941;p=gitmo%2FMoose.git Make sure -metaclass works for Moose too --- diff --git a/t/050_metaclasses/022_new_metaclass.t b/t/050_metaclasses/022_new_metaclass.t new file mode 100644 index 0000000..1eca249 --- /dev/null +++ b/t/050_metaclasses/022_new_metaclass.t @@ -0,0 +1,18 @@ +#!/usr/bin/env perl +use strict; +use warnings; +use Test::More tests => 1; + +do { + package My::Meta::Class; + use Moose; + BEGIN { extends 'Moose::Meta::Class' }; +}; + +do { + package My::Class; + use Moose -metaclass => 'My::Meta::Class'; +}; + +is(My::Class->meta->meta->name, 'My::Meta::Class'); +