r34512 - in /trunk/libtest-poe-server-tcp-perl: ./ debian/ inc/Module/ inc/Module/Install/ lib/Test/POE/Server/ t/

ryan52-guest at users.alioth.debian.org ryan52-guest at users.alioth.debian.org
Thu Apr 30 23:42:58 UTC 2009


Author: ryan52-guest
Date: Thu Apr 30 23:42:53 2009
New Revision: 34512

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=34512
Log:
* New upstream release
* Add myself to Uploaders

Added:
    trunk/libtest-poe-server-tcp-perl/t/11_pause.t
      - copied unchanged from r34511, branches/upstream/libtest-poe-server-tcp-perl/current/t/11_pause.t
Modified:
    trunk/libtest-poe-server-tcp-perl/Changes
    trunk/libtest-poe-server-tcp-perl/MANIFEST
    trunk/libtest-poe-server-tcp-perl/META.yml
    trunk/libtest-poe-server-tcp-perl/debian/changelog
    trunk/libtest-poe-server-tcp-perl/debian/control
    trunk/libtest-poe-server-tcp-perl/inc/Module/Install.pm
    trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Base.pm
    trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Can.pm
    trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Fetch.pm
    trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Makefile.pm
    trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Metadata.pm
    trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Win32.pm
    trunk/libtest-poe-server-tcp-perl/inc/Module/Install/WriteAll.pm
    trunk/libtest-poe-server-tcp-perl/lib/Test/POE/Server/TCP.pm

Modified: trunk/libtest-poe-server-tcp-perl/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtest-poe-server-tcp-perl/Changes?rev=34512&op=diff
==============================================================================
--- trunk/libtest-poe-server-tcp-perl/Changes (original)
+++ trunk/libtest-poe-server-tcp-perl/Changes Thu Apr 30 23:42:53 2009
@@ -1,5 +1,9 @@
 Test::POE::Server::TCP
 ======================
+
+1.04	Thu Apr 30 15:09:08 BST 2009
+	- Applied patch from Martijn van Beers that adds pause/resume 
+	  listening methods.
 
 1.02	Tue Apr  7 21:10:28 BST 2009
 	- Make auto_set_repository() only run at author-time

Modified: trunk/libtest-poe-server-tcp-perl/MANIFEST
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtest-poe-server-tcp-perl/MANIFEST?rev=34512&op=diff
==============================================================================
--- trunk/libtest-poe-server-tcp-perl/MANIFEST (original)
+++ trunk/libtest-poe-server-tcp-perl/MANIFEST Thu Apr 30 23:42:53 2009
@@ -25,5 +25,6 @@
 t/08_buffer.t
 t/09_client_info.t
 t/10_prefix.t
+t/11_pause.t
 t/99_pod.t
 t/99_pod_coverage.t

Modified: trunk/libtest-poe-server-tcp-perl/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtest-poe-server-tcp-perl/META.yml?rev=34512&op=diff
==============================================================================
--- trunk/libtest-poe-server-tcp-perl/META.yml (original)
+++ trunk/libtest-poe-server-tcp-perl/META.yml Thu Apr 30 23:42:53 2009
@@ -3,12 +3,13 @@
 author:
   - 'Chris Williams <chris at bingosnet.co.uk>'
 build_requires:
+  ExtUtils::MakeMaker: 6.42
   Test::More: 0.47
   Text::ParseWords: 0
 configure_requires:
-  ExtUtils::MakeMaker: 6.50
+  ExtUtils::MakeMaker: 6.42
 distribution_type: module
-generated_by: 'Module::Install version 0.81'
+generated_by: 'Module::Install version 0.85'
 license: perl
 meta-spec:
   url: http://module-build.sourceforge.net/META-spec-v1.4.html
@@ -29,4 +30,4 @@
 resources:
   license: http://dev.perl.org/licenses/
   repository: git://github.com/bingos/test-poe-server-tcp.git
-version: 1.02
+version: 1.04

Modified: trunk/libtest-poe-server-tcp-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtest-poe-server-tcp-perl/debian/changelog?rev=34512&op=diff
==============================================================================
--- trunk/libtest-poe-server-tcp-perl/debian/changelog (original)
+++ trunk/libtest-poe-server-tcp-perl/debian/changelog Thu Apr 30 23:42:53 2009
@@ -1,3 +1,10 @@
+libtest-poe-server-tcp-perl (1.04-1) UNRELEASED; urgency=low
+
+  * New upstream release
+  * Add myself to Uploaders
+
+ -- Ryan Niebur <ryanryan52 at gmail.com>  Thu, 30 Apr 2009 16:42:43 -0700
+
 libtest-poe-server-tcp-perl (1.02-1) unstable; urgency=low
 
   * New upstream release.

Modified: trunk/libtest-poe-server-tcp-perl/debian/control
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtest-poe-server-tcp-perl/debian/control?rev=34512&op=diff
==============================================================================
--- trunk/libtest-poe-server-tcp-perl/debian/control (original)
+++ trunk/libtest-poe-server-tcp-perl/debian/control Thu Apr 30 23:42:53 2009
@@ -6,7 +6,7 @@
  libtest-pod-perl, libtest-pod-coverage-perl, netbase
 Maintainer: Debian Perl Group <pkg-perl-maintainers at lists.alioth.debian.org>
 Uploaders: Antonio Radici <antonio at dyne.org>,
- gregor herrmann <gregoa at debian.org>
+ gregor herrmann <gregoa at debian.org>, Ryan Niebur <ryanryan52 at gmail.com>
 Standards-Version: 3.8.1
 Homepage: http://search.cpan.org/dist/Test-POE-Server-TCP/
 Vcs-Svn: svn://svn.debian.org/pkg-perl/trunk/libtest-poe-server-tcp

Modified: trunk/libtest-poe-server-tcp-perl/inc/Module/Install.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtest-poe-server-tcp-perl/inc/Module/Install.pm?rev=34512&op=diff
==============================================================================
--- trunk/libtest-poe-server-tcp-perl/inc/Module/Install.pm (original)
+++ trunk/libtest-poe-server-tcp-perl/inc/Module/Install.pm Thu Apr 30 23:42:53 2009
@@ -17,12 +17,10 @@
 #     3. The ./inc/ version of Module::Install loads
 # }
 
-BEGIN {
-	require 5.004;
-}
+use 5.005;
 use strict 'vars';
 
-use vars qw{$VERSION};
+use vars qw{$VERSION $MAIN};
 BEGIN {
 	# All Module::Install core packages now require synchronised versions.
 	# This will be used to ensure we don't accidentally load old or
@@ -30,7 +28,10 @@
 	# This is not enforced yet, but will be some time in the next few
 	# releases once we can make sure it won't clash with custom
 	# Module::Install extensions.
-	$VERSION = '0.81';
+	$VERSION = '0.85';
+
+	# Storage for the pseudo-singleton
+	$MAIN    = undef;
 
 	*inc::Module::Install::VERSION = *VERSION;
 	@inc::Module::Install::ISA     = __PACKAGE__;
@@ -93,6 +94,7 @@
 
 
 
+
 # Build.PL was formerly supported, but no longer is due to excessive
 # difficulty in implementing every single feature twice.
 if ( $0 =~ /Build.PL$/i ) { die <<"END_DIE" }
@@ -131,14 +133,22 @@
 	$sym->{$cwd} = sub {
 		my $pwd = Cwd::cwd();
 		if ( my $code = $sym->{$pwd} ) {
-			# delegate back to parent dirs
+			# Delegate back to parent dirs
 			goto &$code unless $cwd eq $pwd;
 		}
 		$$sym =~ /([^:]+)$/ or die "Cannot autoload $who - $sym";
-		unless ( uc($1) eq $1 ) {
-			unshift @_, ( $self, $1 );
-			goto &{$self->can('call')};
+		my $method = $1;
+		if ( uc($method) eq $method ) {
+			# Do nothing
+			return;
+		} elsif ( $method =~ /^_/ and $self->can($method) ) {
+			# Dispatch to the root M:I class
+			return $self->$method(@_);
 		}
+
+		# Dispatch to the appropriate plugin
+		unshift @_, ( $self, $1 );
+		goto &{$self->can('call')};
 	};
 }
 
@@ -163,6 +173,9 @@
 	delete $INC{"$self->{file}"};
 	delete $INC{"$self->{path}.pm"};
 
+	# Save to the singleton
+	$MAIN = $self;
+
 	return 1;
 }
 
@@ -176,8 +189,7 @@
 
 	my @exts = @{$self->{extensions}};
 	unless ( @exts ) {
-		my $admin = $self->{admin};
-		@exts = $admin->load_all_extensions;
+		@exts = $self->{admin}->load_all_extensions;
 	}
 
 	my %seen;
@@ -260,7 +272,7 @@
 sub load_extensions {
 	my ($self, $path, $top) = @_;
 
-	unless ( grep { !ref $_ and lc $_ eq lc $self->{prefix} } @INC ) {
+	unless ( grep { ! ref $_ and lc $_ eq lc $self->{prefix} } @INC ) {
 		unshift @INC, $self->{prefix};
 	}
 

Modified: trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Base.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Base.pm?rev=34512&op=diff
==============================================================================
--- trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Base.pm (original)
+++ trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Base.pm Thu Apr 30 23:42:53 2009
@@ -1,7 +1,11 @@
 #line 1
 package Module::Install::Base;
 
-$VERSION = '0.81';
+use strict 'vars';
+use vars qw{$VERSION};
+BEGIN {
+	$VERSION = '0.85';
+}
 
 # Suspend handler for "redefined" warnings
 BEGIN {
@@ -12,51 +16,61 @@
 ### This is the ONLY module that shouldn't have strict on
 # use strict;
 
-#line 41
+#line 45
 
 sub new {
-    my ($class, %args) = @_;
+	my ($class, %args) = @_;
 
-    foreach my $method ( qw(call load) ) {
-        *{"$class\::$method"} = sub {
-            shift()->_top->$method(@_);
-        } unless defined &{"$class\::$method"};
-    }
+	foreach my $method ( qw(call load) ) {
+		next if defined &{"$class\::$method"};
+		*{"$class\::$method"} = sub {
+			shift()->_top->$method(@_);
+		};
+	}
 
-    bless( \%args, $class );
+	bless( \%args, $class );
 }
 
-#line 61
+#line 66
 
 sub AUTOLOAD {
-    my $self = shift;
-    local $@;
-    my $autoload = eval { $self->_top->autoload } or return;
-    goto &$autoload;
+	my $self = shift;
+	local $@;
+	my $autoload = eval {
+		$self->_top->autoload
+	} or return;
+	goto &$autoload;
 }
 
-#line 76
+#line 83
 
-sub _top { $_[0]->{_top} }
+sub _top {
+	$_[0]->{_top};
+}
 
-#line 89
+#line 98
 
 sub admin {
-    $_[0]->_top->{admin} or Module::Install::Base::FakeAdmin->new;
+	$_[0]->_top->{admin}
+	or
+	Module::Install::Base::FakeAdmin->new;
 }
 
-#line 101
+#line 114
 
 sub is_admin {
-    $_[0]->admin->VERSION;
+	$_[0]->admin->VERSION;
 }
 
 sub DESTROY {}
 
 package Module::Install::Base::FakeAdmin;
 
-my $Fake;
-sub new { $Fake ||= bless(\@_, $_[0]) }
+my $fake;
+
+sub new {
+	$fake ||= bless(\@_, $_[0]);
+}
 
 sub AUTOLOAD {}
 
@@ -69,4 +83,4 @@
 
 1;
 
-#line 146
+#line 162

Modified: trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Can.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Can.pm?rev=34512&op=diff
==============================================================================
--- trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Can.pm (original)
+++ trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Can.pm Thu Apr 30 23:42:53 2009
@@ -9,7 +9,7 @@
 
 use vars qw{$VERSION $ISCORE @ISA};
 BEGIN {
-	$VERSION = '0.81';
+	$VERSION = '0.85';
 	$ISCORE  = 1;
 	@ISA     = qw{Module::Install::Base};
 }

Modified: trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Fetch.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Fetch.pm?rev=34512&op=diff
==============================================================================
--- trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Fetch.pm (original)
+++ trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Fetch.pm Thu Apr 30 23:42:53 2009
@@ -6,7 +6,7 @@
 
 use vars qw{$VERSION $ISCORE @ISA};
 BEGIN {
-	$VERSION = '0.81';
+	$VERSION = '0.85';
 	$ISCORE  = 1;
 	@ISA     = qw{Module::Install::Base};
 }

Modified: trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Makefile.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Makefile.pm?rev=34512&op=diff
==============================================================================
--- trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Makefile.pm (original)
+++ trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Makefile.pm Thu Apr 30 23:42:53 2009
@@ -7,7 +7,7 @@
 
 use vars qw{$VERSION $ISCORE @ISA};
 BEGIN {
-	$VERSION = '0.81';
+	$VERSION = '0.85';
 	$ISCORE  = 1;
 	@ISA     = qw{Module::Install::Base};
 }
@@ -114,17 +114,32 @@
 	my $self = shift;
 	die "&Makefile->write() takes no arguments\n" if @_;
 
-	# Make sure we have a new enough
+	# Check the current Perl version
+	my $perl_version = $self->perl_version;
+	if ( $perl_version ) {
+		eval "use $perl_version; 1"
+			or die "ERROR: perl: Version $] is installed, "
+			. "but we need version >= $perl_version";
+	}
+
+	# Make sure we have a new enough MakeMaker
 	require ExtUtils::MakeMaker;
 
-	# MakeMaker can complain about module versions that include
-	# an underscore, even though its own version may contain one!
-	# Hence the funny regexp to get rid of it.  See RT #35800
-	# for details.
-
-	$self->configure_requires( 'ExtUtils::MakeMaker' => $ExtUtils::MakeMaker::VERSION =~ /^(\d+\.\d+)/ );
-
-	# Generate the
+	if ( $perl_version and $self->_cmp($perl_version, '5.006') >= 0 ) {
+		# MakeMaker can complain about module versions that include
+		# an underscore, even though its own version may contain one!
+		# Hence the funny regexp to get rid of it.  See RT #35800
+		# for details.
+		$self->build_requires( 'ExtUtils::MakeMaker' => $ExtUtils::MakeMaker::VERSION =~ /^(\d+\.\d+)/ );
+		$self->configure_requires( 'ExtUtils::MakeMaker' => $ExtUtils::MakeMaker::VERSION =~ /^(\d+\.\d+)/ );
+	} else {
+		# Allow legacy-compatibility with 5.005 by depending on the
+		# most recent EU:MM that supported 5.005.
+		$self->build_requires( 'ExtUtils::MakeMaker' => 6.42 );
+		$self->configure_requires( 'ExtUtils::MakeMaker' => 6.42 );
+	}
+
+	# Generate the MakeMaker params
 	my $args = $self->makemaker_args;
 	$args->{DISTNAME} = $self->name;
 	$args->{NAME}     = $self->module_name || $self->name;
@@ -133,7 +148,7 @@
 	if ( $self->tests ) {
 		$args->{test} = { TESTS => $self->tests };
 	}
-	if ($] >= 5.005) {
+	if ( $] >= 5.005 ) {
 		$args->{ABSTRACT} = $self->abstract;
 		$args->{AUTHOR}   = $self->author;
 	}
@@ -147,7 +162,7 @@
 		delete $args->{SIGN};
 	}
 
-	# merge both kinds of requires into prereq_pm
+	# Merge both kinds of requires into prereq_pm
 	my $prereq = ($args->{PREREQ_PM} ||= {});
 	%$prereq = ( %$prereq,
 		map { @$_ }
@@ -250,4 +265,4 @@
 
 __END__
 
-#line 379
+#line 394

Modified: trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Metadata.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Metadata.pm?rev=34512&op=diff
==============================================================================
--- trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Metadata.pm (original)
+++ trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Metadata.pm Thu Apr 30 23:42:53 2009
@@ -6,7 +6,7 @@
 
 use vars qw{$VERSION @ISA $ISCORE};
 BEGIN {
-	$VERSION = '0.81';
+	$VERSION = '0.85';
 	@ISA     = qw{Module::Install::Base};
 	$ISCORE  = 1;
 }

Modified: trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Win32.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Win32.pm?rev=34512&op=diff
==============================================================================
--- trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Win32.pm (original)
+++ trunk/libtest-poe-server-tcp-perl/inc/Module/Install/Win32.pm Thu Apr 30 23:42:53 2009
@@ -6,7 +6,7 @@
 
 use vars qw{$VERSION @ISA $ISCORE};
 BEGIN {
-	$VERSION = '0.81';
+	$VERSION = '0.85';
 	@ISA     = qw{Module::Install::Base};
 	$ISCORE  = 1;
 }

Modified: trunk/libtest-poe-server-tcp-perl/inc/Module/Install/WriteAll.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtest-poe-server-tcp-perl/inc/Module/Install/WriteAll.pm?rev=34512&op=diff
==============================================================================
--- trunk/libtest-poe-server-tcp-perl/inc/Module/Install/WriteAll.pm (original)
+++ trunk/libtest-poe-server-tcp-perl/inc/Module/Install/WriteAll.pm Thu Apr 30 23:42:53 2009
@@ -6,7 +6,7 @@
 
 use vars qw{$VERSION @ISA $ISCORE};
 BEGIN {
-	$VERSION = '0.81';
+	$VERSION = '0.85';
 	@ISA     = qw{Module::Install::Base};
 	$ISCORE  = 1;
 }

Modified: trunk/libtest-poe-server-tcp-perl/lib/Test/POE/Server/TCP.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtest-poe-server-tcp-perl/lib/Test/POE/Server/TCP.pm?rev=34512&op=diff
==============================================================================
--- trunk/libtest-poe-server-tcp-perl/lib/Test/POE/Server/TCP.pm (original)
+++ trunk/libtest-poe-server-tcp-perl/lib/Test/POE/Server/TCP.pm Thu Apr 30 23:42:53 2009
@@ -7,7 +7,7 @@
 use Carp qw(carp croak);
 use vars qw($VERSION);
 
-$VERSION = '1.02';
+$VERSION = '1.04';
 
 sub spawn {
   my $package = shift;
@@ -38,6 +38,16 @@
   return $_[0]->{session_id};
 }
 
+sub pause_listening {
+  return unless $_[0]->{listener};
+  $_[0]->{listener}->pause_accept();
+}
+
+sub resume_listening {
+  return unless $_[0]->{listener};
+  $_[0]->{listener}->resume_accept();
+}
+
 sub getsockname {
   return unless $_[0]->{listener};
   return $_[0]->{listener}->getsockname();
@@ -673,6 +683,14 @@
 
 Immediately disconnects a client conenction. Requires a valid client ID as a parameter.
 
+=item C<pause_listening>
+
+Stops the underlying listening socket from accepting new connections. This lets you test whether you handle the connection timing out gracefully.
+
+=item C<resume_listening>
+
+The companion of C<pause_listening>
+
 =item C<getsockname>
 
 Access to the L<POE::Wheel::SocketFactory> method of the underlying listening socket.
@@ -764,7 +782,7 @@
 
 =head1 LICENSE
 
-Copyright C<(c)> Chris Williams, Rocco Caputo, Ann Barcomb and Jos Boumans.
+Copyright E<copy> Chris Williams, Rocco Caputo, Ann Barcomb and Jos Boumans.
 
 This module may be used, modified, and distributed under the same terms as Perl itself. Please see the license that came with your Perl distribution for details.
 




More information about the Pkg-perl-cvs-commits mailing list