]> git.vpit.fr Git - perl/modules/IPC-MorseSignals.git/blobdiff - t/70-speed.t
Update VPIT::TestHelpers to 15e8aee3
[perl/modules/IPC-MorseSignals.git] / t / 70-speed.t
index fc6f031e7d43b19bf4d95fb67f4ce8a714b0590f..9eba2d9b822207760ded59d6cb962a4b55630d82 100644 (file)
@@ -5,19 +5,22 @@ use warnings;
 
 use utf8;
 
-use Test::More tests => 3;
+my $n;
+use Test::More tests => 1 + ($n = 5);
 
 use lib 't/lib';
-use IPC::MorseSignals::TestSuite qw/bench init cleanup/;
+use IPC::MorseSignals::TestSuite qw<bench init cleanup>;
+
+*IPC::MorseSignals::TestSuite::diag = *Test::More::diag;
 
-my $diag = sub { diag @_ };
 my @res;
 
-init 12;
+init 2 * $n;
 
-ok(bench(4,  1, $diag, \@res));
-ok(bench(4,  4, $diag, \@res));
-ok(bench(16, 1, $diag, \@res));
+TODO: {
+ local $TODO = 'This is just to give you a measure of which speed you should use';
+ ok(bench(2 ** ($n - $_),  2 ** $_, \@res)) for 0 .. $n;
+}
 
 cleanup;