Skip to content

Commit

Permalink
*::VERSION is always defined now
Browse files Browse the repository at this point in the history
  • Loading branch information
karenetheridge committed Apr 6, 2016
1 parent 2795074 commit 823c16e
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 10 deletions.
6 changes: 2 additions & 4 deletions lib/Moose.pm
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,8 @@ use Moose::Exporter;

use Class::MOP;

BEGIN {
die "Class::MOP version $Moose::VERSION required--this is version $Class::MOP::VERSION"
if $Moose::VERSION && $Class::MOP::VERSION ne $Moose::VERSION;
}
die "Class::MOP version $Moose::VERSION required--this is version $Class::MOP::VERSION"
if $Class::MOP::VERSION ne $Moose::VERSION;

use Moose::Meta::Class;
use Moose::Meta::TypeConstraint;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,6 @@

=begin testing-SETUP

# because MooseX::NonMoose has a version requirement
BEGIN { $Moose::Role::VERSION = 9999 unless $Moose::Role::VERSION }

use Test::Requires {
'DateTime' => '0',
'DateTime::Calendar::Mayan' => '0',
Expand Down
5 changes: 2 additions & 3 deletions t/cmop/self_introspection.t
Original file line number Diff line number Diff line change
Expand Up @@ -323,9 +323,8 @@ is($class_mop_class_meta->find_attribute_by_name('attribute_metaclass')->default
is($class_mop_class_meta->name, 'Class::MOP::Class', '... Class::MOP::Class->name');
is($class_mop_class_meta->version, $Class::MOP::Class::VERSION, '... Class::MOP::Class->version');

if ( defined $Class::MOP::Class::VERSION ) {
ok($class_mop_class_meta->has_package_symbol('$VERSION'), '... Class::MOP::Class->has_package_symbol($VERSION)');
}
ok($class_mop_class_meta->has_package_symbol('$VERSION'), '... Class::MOP::Class->has_package_symbol($VERSION)');

is(${$class_mop_class_meta->get_package_symbol('$VERSION')},
$Class::MOP::Class::VERSION,
'... Class::MOP::Class->get_package_symbol($VERSION)');
Expand Down

0 comments on commit 823c16e

Please sign in to comment.