r48191 - in /branches/upstream/libipc-system-simple-perl/current: Changes lib/IPC/System/Simple.pm t/win32.t

jawnsy-guest at users.alioth.debian.org jawnsy-guest at users.alioth.debian.org
Fri Dec 4 14:14:18 UTC 2009


Author: jawnsy-guest
Date: Fri Dec  4 14:14:12 2009
New Revision: 48191

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=48191
Log:
[svn-upgrade] Integrating new upstream version, libipc-system-simple-perl (1.19)

Modified:
    branches/upstream/libipc-system-simple-perl/current/Changes
    branches/upstream/libipc-system-simple-perl/current/lib/IPC/System/Simple.pm
    branches/upstream/libipc-system-simple-perl/current/t/win32.t

Modified: branches/upstream/libipc-system-simple-perl/current/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libipc-system-simple-perl/current/Changes?rev=48191&op=diff
==============================================================================
--- branches/upstream/libipc-system-simple-perl/current/Changes (original)
+++ branches/upstream/libipc-system-simple-perl/current/Changes Fri Dec  4 14:14:12 2009
@@ -1,4 +1,14 @@
 Revision history for Perl extension IPC::System::Simple.
+
+1.19  Fri Dec  4 14:14:25 EST 2009
+
+        * TEST: Added tests to ensure correct behaviour when
+          calling commands in Windows which are contained in directories
+          that contain spaces. (These tests are currently skiped,
+          as they're testing for a known bug.)
+
+        * BUGFIX: Spurious warnings about redefining POSIX macros
+          no longer plague Windows systems.
 
 1.18  Sun Feb  8 19:09:15 AUSEDT 2009
 

Modified: branches/upstream/libipc-system-simple-perl/current/lib/IPC/System/Simple.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libipc-system-simple-perl/current/lib/IPC/System/Simple.pm?rev=48191&op=diff
==============================================================================
--- branches/upstream/libipc-system-simple-perl/current/lib/IPC/System/Simple.pm (original)
+++ branches/upstream/libipc-system-simple-perl/current/lib/IPC/System/Simple.pm Fri Dec  4 14:14:12 2009
@@ -84,7 +84,7 @@
     $EXITVAL EXIT_ANY
 );
 
-our $VERSION = '1.18';
+our $VERSION = '1.19';
 our $EXITVAL = -1;
 
 my @Signal_from_number = split(' ', $Config{sig_name});
@@ -106,6 +106,7 @@
 eval { WIFEXITED(0); };
 
 if ($@ =~ UNDEFINED_POSIX_RE) {
+        no warnings 'redefine';  ## no critic
 	*WIFEXITED   = sub { not $_[0] & 0xff };
 	*WEXITSTATUS = sub { $_[0] >> 8  };
 	*WIFSIGNALED = sub { $_[0] & 127 };

Modified: branches/upstream/libipc-system-simple-perl/current/t/win32.t
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libipc-system-simple-perl/current/t/win32.t?rev=48191&op=diff
==============================================================================
--- branches/upstream/libipc-system-simple-perl/current/t/win32.t (original)
+++ branches/upstream/libipc-system-simple-perl/current/t/win32.t Fri Dec  4 14:14:12 2009
@@ -2,7 +2,7 @@
 use strict;
 use Test::More;
 use File::Basename qw(fileparse);
-use IPC::System::Simple qw(run capture $EXITVAL);
+use IPC::System::Simple qw(run capture $EXITVAL capturex);
 use Config;
 
 BEGIN {
@@ -23,7 +23,11 @@
 # This command should allow us to exit with a specific value.
 use constant EXIT_CMD => [ @{ &IPC::System::Simple::WINDOWS_SHELL }, 'exit'];
 
-plan tests => 28;
+# These are used in the testing of commands in paths which contain spaces.
+use constant CMD_WITH_SPACES        => 'dir with spaces\hello.exe';
+use constant CMD_WITH_SPACES_OUTPUT => "Hello World\n";
+
+plan tests => 32;
 
 my $perl_path = $Config{perlpath};
 $perl_path .= $Config{_exe} unless $perl_path =~ m/$Config{_exe}$/i;
@@ -112,3 +116,24 @@
 
 run($raw_perl,"-e1");
 ok(1,"raw perl found in multi-part path");
+
+# Check to ensure we can run commands that include spaces.
+
+SKIP: {
+
+    # CMD_WITH_SPACES is not currently distributed with IPC::System::Simple,
+    # effectively making this an author test for now. -- PJF, Dec 4, 2009
+
+    skip(CMD_WITH_SPACES." not available", 2) unless -x CMD_WITH_SPACES;
+
+    my $output = eval { capturex(CMD_WITH_SPACES); };
+
+    is($@, "", "command with spaces should not error (capturex)");
+    is($output, CMD_WITH_SPACES_OUTPUT, "...and give correct output");
+
+    my $output = eval { capture(CMD_WITH_SPACES); };
+
+    is($@, "", "command with spaces should not error (capture)");
+    is($output, CMD_WITH_SPACES_OUTPUT, "...and give correct output");
+
+}




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