6 use Test::More tests => 10;
8 use Variable::Magic qw/wizard cast dispell/;
14 for (0 .. 11) { return 0 unless $c[$_] == $x[$_]; }
19 my $wiz = wizard get => sub { ++$c[0] },
20 set => sub { ++$c[1] },
21 len => sub { ++$c[2] },
22 clear => sub { ++$c[3] },
23 free => sub { ++$c[4] },
24 copy => sub { ++$c[5] },
25 dup => sub { ++$c[6] },
26 local => sub { ++$c[7] },
27 fetch => sub { ++$c[8] },
28 store => sub { ++$c[9] },
29 'exists' => sub { ++$c[10] },
30 'delete' => sub { ++$c[11] };
31 ok(check(), 'code : create wizard');
38 ok(check(), 'code : cast');
42 ok(check(), 'code : assign to');
46 ok(check(), 'code : interpolate');
49 ok(check(), 'code : reference');
53 ok(check(), 'code : assign');
56 ok(check(), 'code : call');
63 ok(check(), 'code : scope end');
67 ok(check(), 'code : undef');
70 ok(check(), 'code : dispell');