X-Git-Url: http://git.vpit.fr/?a=blobdiff_plain;f=t%2F23-clear.t;h=3f7f57e7ed8d0928b4a5db1c36aa65ad93352ea7;hb=da422089a9a5dfbf84e72ec3ba867063471ff41c;hp=d07d4b01958b843a26be53ebd793752f3cd9bdd9;hpb=505fda7126b01811c0ca990552876a1c6d9dc7c3;p=perl%2Fmodules%2FVariable-Magic.git diff --git a/t/23-clear.t b/t/23-clear.t index d07d4b0..3f7f57e 100644 --- a/t/23-clear.t +++ b/t/23-clear.t @@ -10,18 +10,18 @@ use Variable::Magic qw/cast/; use lib 't/lib'; use Variable::Magic::TestWatcher; -my $wiz = init 'clear', 'clear'; +my $wiz = init_watcher 'clear', 'clear'; my @a = qw/a b c/; -check { cast @a, $wiz } { }, 'cast array'; +watch { cast @a, $wiz } { }, 'cast array'; -check { @a = () } { clear => 1 }, 'clear array'; +watch { @a = () } { clear => 1 }, 'clear array'; is_deeply \@a, [ ], 'clear: clear array correctly'; my %h = (foo => 1, bar => 2); -check { cast %h, $wiz } { }, 'cast hash'; +watch { cast %h, $wiz } { }, 'cast hash'; -check { %h = () } { clear => 1 }, 'clear hash'; +watch { %h = () } { clear => 1 }, 'clear hash'; is_deeply \%h, { }, 'clear: clear hash correctly';