Subject: | syntax error in t/Jabber-SimpleSend.t (Jabber::SimpleSend 0.02) |
There's a syntax error in the test script (which is mostly commented out, in any case!).
Corrected version attached, with the line comments change to a pod comment instead.
Cheers,
Stephen
Subject: | Jabber-SimpleSend.t |
#!perl
use strict;
use Test::More tests => 1;
BEGIN { use_ok( 'Jabber::SimpleSend',qw( send_jabber_message ) ) }
=FOR the_developer_only
use Sys::Hostname;
use LWP;
BEGIN { die "Cannot run tests with test_config" unless (-f 't/test_config'); }
open(FILE,'< t/test_config');
my $user = <FILE>; chomp $user;
my $password = <FILE>; chomp $password;
my $string = hostname().join(':',localtime(time()));
send_jabber_message({
user => $user,
password => $password,
target => 'jsst@jabber.mccarroll.org.uk',
subject => 'testing',
message => $string});
print STDERR "\nSleeping for 5 seconds to allow the bot to do its work\n";
sleep 5; # give it some
my $url = 'http://www.mccarroll.org.uk/~gem/jsst';
my $ua = LWP::UserAgent->new;
my $response = $ua->get($url);
my $results = {};
ok($response->is_success);
ok($response->content =~ m/$string/);
=END