X-Git-Url: http://git.vpit.fr/?a=blobdiff_plain;f=t%2F31-array.t;h=a7496a9a338c4d69b6f59e9d470d24dbcb426d7c;hb=751094f5d7b43171afc7104e957ca7fe2d21eb34;hp=bb2f96e402b5101e61e627c2739229709fa7ae72;hpb=14f66d40970bef63105be046a109c1a32859a8a0;p=perl%2Fmodules%2FVariable-Magic.git diff --git a/t/31-array.t b/t/31-array.t index bb2f96e..a7496a9 100644 --- a/t/31-array.t +++ b/t/31-array.t @@ -7,11 +7,11 @@ use Test::More tests => 21; use Variable::Magic qw/wizard cast dispell/; -my @c = (0) x 5; -my @x = (0) x 5; +my @c = (0) x 12; +my @x = (0) x 12; sub check { - for (0 .. 4) { return 0 unless $c[$_] == $x[$_]; } + for (0 .. 11) { return 0 unless $c[$_] == $x[$_]; } return 1; } @@ -19,7 +19,14 @@ my $wiz = wizard get => sub { ++$c[0] }, set => sub { ++$c[1] }, len => sub { ++$c[2]; $_[2] }, clear => sub { ++$c[3] }, - free => sub { ++$c[4] }; + free => sub { ++$c[4] }, + copy => sub { ++$c[5] }, + dup => sub { ++$c[6] }, + local => sub { ++$c[7] }, + fetch => sub { ++$c[8] }, + store => sub { ++$c[9] }, + 'exists' => sub { ++$c[10] }, + 'delete' => sub { ++$c[11] }; ok(check(), 'array : create wizard'); my @n = map { int rand 1000 } 1 .. 5;