4 use Test::More tests => 3;
13 push @called, 'Class::BUILD';
18 push @called, 'Class::BUILDALL';
19 $self->SUPER::BUILDALL(@_);
27 push @called, 'Child::BUILD';
32 push @called, 'Child::BUILDALL';
33 $self->SUPER::BUILDALL(@_);
37 is_deeply([splice @called], [], "no BUILD calls yet");
39 my $object = Class->new;
41 is_deeply([splice @called], ["Class::BUILDALL", "Class::BUILD"]);
43 my $child = Child->new;
45 is_deeply([splice @called], ["Child::BUILDALL", "Class::BUILDALL", "Class::BUILD", "Child::BUILD"]);