Remove useless comments and add shebang to test
[poe-component-irc-plugin-hello.git] / t / POE-Component-IRC-Plugin-Hello.t
index ebb2ef597dd35746ba8c0810548304e87810f74c..7eae8c836340f10db51c75184d4581d9a1134ff2 100644 (file)
@@ -1,3 +1,4 @@
+#!/usr/bin/perl -w
 use v5.14;
 use strict;
 use warnings;
@@ -7,7 +8,6 @@ use Test::MockObject;
 
 BEGIN { use_ok('POE::Component::IRC::Plugin::Hello') };
 
-# Variable setup
 my $hello_sent;
 
 my $mockirc = Test::MockObject->new;
@@ -16,15 +16,13 @@ $mockirc->mock(yield => sub { $hello_sent = 1 })->set_always(nick_name => 'hello
 my $self = POE::Component::IRC::Plugin::Hello->new;
 my $channels = [ '#chan' ];
 
-# Sub setup
 sub runtest{
-  my ($message, $expect, $comment) = @_;
-  $hello_sent=0;
-  $self->S_public($mockirc, \'mgv!marius@ieval.ro', \$channels, \$message);
-  ok($hello_sent == $expect, $comment)
+       my ($message, $expect, $comment) = @_;
+       $hello_sent=0;
+       $self->S_public($mockirc, \'mgv!marius@ieval.ro', \$channels, \$message);
+       ok($hello_sent == $expect, $comment)
 }
 
-#Tests
 runtest 'privet', 1, 'simple privet';
 runtest 'PrIvEt', 1, 'privet in mixed case';
 runtest '  privet  ', 1, 'privet with spaces';
This page took 0.010633 seconds and 4 git commands to generate.