]> git.vpit.fr Git - perl/modules/Sub-Nary.git/blobdiff - t/22-call.t
One more test to exaust for cases. Remove debugging cruft
[perl/modules/Sub-Nary.git] / t / 22-call.t
index fdd3812fcdfac933dafba9e12f01de1c75e2d5e3..6aa786333a1bebd54980c6a27c63267796510e74 100644 (file)
@@ -3,7 +3,7 @@
 use strict;
 use warnings;
 
-use Test::More tests => 41;
+use Test::More tests => 42;
 
 use Sub::Nary;
 
@@ -24,6 +24,8 @@ sub rec1 { rec2(); }
 sub rec2 { rec1(); }
 
 my @tests = (
+ [ sub { hlaghlaghlagh() }, 'list' ],
+
  [ sub { zero }, 0 ],
  [ sub { one  }, 1 ],
  [ sub { two  }, 2 ],
@@ -80,6 +82,7 @@ my @tests = (
 my $i = 1;
 for (@tests) {
  my $r = $sn->nary($_->[0]);
- is_deeply($r, { $_->[1] => 1 }, 'call test ' . $i);
+ my $exp = ref $_->[1] ? $_->[1] : { $_->[1] => 1 };
+ is_deeply($r, $exp, 'call test ' . $i);
  ++$i;
 }