In perl.git, the branch blead has been updated

<http://perl5.git.perl.org/perl.git/commitdiff/74b2b4b1788882713af5484605612fc6ec67405d?hp=bd0ab00df494c0f393ee5623b3a949ae9e0ae15e>

- Log -----------------------------------------------------------------
commit 74b2b4b1788882713af5484605612fc6ec67405d
Author: Nicholas Clark <[email protected]>
Date:   Sun Jul 26 11:30:32 2009 +0100

    Add tests for where -C differs between then #! and command lines.
-----------------------------------------------------------------------

Summary of changes:
 t/run/switchC.t |   14 +++++++++++++-
 1 files changed, 13 insertions(+), 1 deletions(-)

diff --git a/t/run/switchC.t b/t/run/switchC.t
index 9e52ad3..38e79a1 100644
--- a/t/run/switchC.t
+++ b/t/run/switchC.t
@@ -13,7 +13,7 @@ BEGIN {
 
 BEGIN { require "./test.pl"; }
 
-plan(tests => 7);
+plan(tests => 9);
 
 my $r;
 
@@ -63,3 +63,15 @@ $r = runperl( switches => [ '-CS', '-w' ],
              prog     => "#!perl -CS\nprint chr(256)",
               stderr   => 1, );
 like( $r, qr/^$b(?:\r?\n)?$/s, '#!perl -C' );
+
+$r = runperl( switches => [ '-CA', '-w' ],
+             prog     => "#!perl -CS\nprint chr(256)",
+              stderr   => 1, );
+like( $r, qr/^Too late for "-CS" option at -e line 1\.$/s,
+      '#!perl -C with different -C on command line' );
+
+$r = runperl( switches => [ '-w' ],
+             prog     => "#!perl -CS\nprint chr(256)",
+              stderr   => 1, );
+like( $r, qr/^Too late for "-CS" option at -e line 1\.$/s,
+      '#!perl -C but not command line' );

--
Perl5 Master Repository

Reply via email to