From: Karen Etheridge Date: Sun, 15 Sep 2013 21:12:15 +0000 (-0700) Subject: switch from Class::MOP::class_of to Moose::Util::find_meta X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=bfcecabc3c48500d28a9a648c8e4c8a649a63f66;p=dbsrgits%2FDBIx-Class-Historic.git switch from Class::MOP::class_of to Moose::Util::find_meta --- diff --git a/lib/DBIx/Class.pm b/lib/DBIx/Class.pm index 3ed326f..c14a6af 100644 --- a/lib/DBIx/Class.pm +++ b/lib/DBIx/Class.pm @@ -398,6 +398,8 @@ dyfrgi: Michael Leuchtenburg edenc: Eden Cardim +ether: Karen Etheridge + felliott: Fitz Elliott freetime: Bill Moseley diff --git a/t/55namespaces_cleaned.t b/t/55namespaces_cleaned.t index 254fdd7..176de5e 100644 --- a/t/55namespaces_cleaned.t +++ b/t/55namespaces_cleaned.t @@ -85,11 +85,11 @@ my $skip_idx = { map { $_ => 1 } ( 'DBIx::Class::_Util', ) }; -my $has_cmop = eval { require Class::MOP }; +my $has_moose = eval { require Moose::Util }; # can't use Class::Inspector for the mundane parts as it does not # distinguish imports from anything else, what a crock of... -# Class::MOP is not always available either - hence just do it ourselves +# Moose is not always available either - hence just do it ourselves my $seen; #inheritance means we will see the same method multiple times @@ -105,7 +105,7 @@ for my $mod (@modules) { my %parents = map { $_ => 1 } @{mro::get_linear_isa($mod)}; my %roles; - if ($has_cmop and my $mc = Class::MOP::class_of($mod)) { + if ($has_moose and my $mc = Moose::Util::find_meta($mod)) { if ($mc->can('calculate_all_roles_with_inheritance')) { $roles{$_->name} = 1 for ($mc->calculate_all_roles_with_inheritance); }