X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2F103_Perl6Attribute_test.t;h=8311d0f956b44362e48b98877ae51a3cec50ffe3;hb=41fc2d0fd29483cb704e06198bfaabbcd3e09d08;hp=84e1ea93f9d7c83bb972294fa8dd35891c0109e6;hpb=d6fbcd05c5a7e4bb8a947a603878f3a08b2f5bee;p=gitmo%2FClass-MOP.git diff --git a/t/103_Perl6Attribute_test.t b/t/103_Perl6Attribute_test.t index 84e1ea9..8311d0f 100644 --- a/t/103_Perl6Attribute_test.t +++ b/t/103_Perl6Attribute_test.t @@ -1,20 +1,17 @@ -#!/usr/bin/perl - use strict; use warnings; -use Test::More tests => 10; +use Test::More tests => 9; use File::Spec; -BEGIN { - use_ok('Class::MOP'); - require_ok(File::Spec->catdir('examples', 'Perl6Attribute.pod')); +BEGIN {use Class::MOP; + require_ok(File::Spec->catfile('examples', 'Perl6Attribute.pod')); } { package Foo; - use Class::MOP 'meta'; + use metaclass; Foo->meta->add_attribute(Perl6Attribute->new('$.foo')); Foo->meta->add_attribute(Perl6Attribute->new('@.bar')); @@ -22,8 +19,8 @@ BEGIN { sub new { my $class = shift; - bless $class->meta->construct_instance(@_) => $class; - } + $class->meta->new_object(@_); + } } my $foo = Foo->new();