]> git.vpit.fr Git - perl/modules/Bit-MorseSignals.git/blobdiff - t/31-receiver-plain.t
Importing Bit-MorseSignals-0.06.tar.gz
[perl/modules/Bit-MorseSignals.git] / t / 31-receiver-plain.t
index 9c4326ecd0b165776be6e1cad2367a29fa0b1678..899f3f2d90773933d7c2b3eed5d69e4c08f5fd5f 100644 (file)
@@ -3,7 +3,7 @@
 use strict;
 use warnings;
 
-use Test::More 'no_plan';
+use Test::More tests => 2;
 
 use Bit::MorseSignals::Receiver;
 
@@ -14,6 +14,7 @@ my $pants = new Bit::MorseSignals::Receiver done => sub { $hlagh = $_[1] };
 my $msg  = 'x';
 my @bits = split //, '111110' . '000' . '00011110' . '011111';
 
-$pants->push for @bits;
+$pants->push($_) for @bits;
 
-ok(defined $hlagh && $hlagh eq $msg, 'message properly received');
+is($hlagh,      $msg, 'message properly received');
+is($pants->msg, $msg, 'message properly stored');