Skip Menu |

This queue is for tickets about the Net-Twitter-Stream CPAN distribution.

Report information
The Basics
Id: 55222
Status: new
Priority: 0/
Queue: Net-Twitter-Stream

People
Owner: Nobody in particular
Requestors: BARBIE [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.21
Fixed in: (no value)



Subject: patch to fix CPAN Testers reported FAILs
Patch to fix the test errors reported by CPAN Testers [1]. Also fixed version number, and added missing prerequisite. [1] http://www.cpantesters.org/distro/N/Net-Twitter-Stream.html
Subject: net-twitter-stream.patch
--- Net-Twitter-Stream-0.21/Makefile.PL Mon Nov 16 21:48:50 2009 +++ Net-Twitter-Stream-0.21_01/Makefile.PL Thu Mar 4 14:09:07 2010 @@ -9,6 +9,7 @@ AUTHOR => 'Martin Redmond (@martinredmond)', ABSTRACT => 'Connect to the Twitter streaming api', PREREQ_PM => { - 'Test::Simple' => 0.44, - }, + 'LWP::UserAgent' => 0, + 'Test::Simple' => 0.44, + }, ); --- Net-Twitter-Stream-0.21/lib/Net/Twitter/Stream.pm Mon Nov 16 23:23:23 2009 +++ Net-Twitter-Stream-0.21_01/lib/Net/Twitter/Stream.pm Thu Mar 4 08:51:50 2010 @@ -2,7 +2,7 @@ use strict; use warnings; use LWP::UserAgent; -our $VERSION = '0.2'; +our $VERSION = '0.21'; 1; =head1 NAME --- Net-Twitter-Stream-0.21/t/001_load.t Fri Jul 3 04:45:29 2009 +++ Net-Twitter-Stream-0.21_01/t/001_load.t Thu Mar 4 14:07:31 2010 @@ -2,11 +2,31 @@ # t/001_load.t - check module loading and create testing directory -use Test::More tests => 2; +use Test::More tests => 3; BEGIN { use_ok( 'Net::Twitter::Stream' ); } -my $object = Net::Twitter::Stream->new (); -isa_ok ($object, 'Net::Twitter::Stream'); +my $object; +eval {$object = Net::Twitter::Stream->new (); }; +like($@, qr/Usage:/, '.. requires arguments'); + +my %args = ( + user => 'test', + pass => 'test', + callback => \&show_tweet +); + +eval {$object = Net::Twitter::Stream->new (%args); }; +SKIP: { + skip 1, "Cannot connect to Twitter" if($@); + + isa_ok ($object, 'HTTP::Response'); +} + + +sub show_tweet { + my ( $chunk, $res ) = @_; + return; +}