]> git.vpit.fr Git - perl/modules/IPC-MorseSignals.git/blob - t/30-receiver-obj.t
Get rid of the indirect notation
[perl/modules/IPC-MorseSignals.git] / t / 30-receiver-obj.t
1 #!perl -T
2
3 use strict;
4 use warnings;
5
6 use Test::More tests => 4;
7
8 use IPC::MorseSignals::Receiver;
9
10 my $pants = IPC::MorseSignals::Receiver->new(\%SIG);
11 ok(defined $pants, 'IMR object is defined');
12 is(ref $pants, 'IPC::MorseSignals::Receiver', 'IMR object is valid');
13 ok($pants->isa('Bit::MorseSignals::Receiver'), 'IMR is a BMR');
14
15 my $fake = { };
16 bless $fake, 'IPC::MorseSignal::Hlagh';
17 eval { Bit::MorseSignals::Receiver::reset($fake) };
18 ok($@ && $@ =~ /^First\s+argument/, "BMR methods only apply to BMR objects");