Change 17837 by [EMAIL PROTECTED] on 2002/09/04 13:38:27
Subject: [PATCH lib/Config.t] test grandfathered Config variables
From: Michael G Schwern <[EMAIL PROTECTED]>
Date: Mon, 2 Sep 2002 22:29:07 -0700
Message-ID: <[EMAIL PROTECTED]>
Affected files ...
.... //depot/perl/lib/Config.t#5 edit
Differences ...
==== //depot/perl/lib/Config.t#5 (text) ====
Index: perl/lib/Config.t
--- perl/lib/Config.t#4~17602~ Wed Jul 17 07:43:49 2002
+++ perl/lib/Config.t Wed Sep 4 06:38:27 2002
@@ -4,7 +4,7 @@
require "./test.pl";
}
-plan tests => 23;
+plan tests => 29;
use_ok('Config');
@@ -15,6 +15,16 @@
ok(each %Config);
is($Config{PERL_REVISION}, 5, "PERL_REVISION is 5");
+
+# Check that old config variable names are aliased to their new ones.
+my %grandfathers = ( PERL_VERSION => 'PATCHLEVEL',
+ PERL_SUBVERSION => 'SUBVERSION',
+ PERL_CONFIG_SH => 'CONFIG'
+ );
+while( my($new, $old) = each %grandfathers ) {
+ isnt($Config{$new}, undef, "$new is defined");
+ is($Config{$new}, $Config{$old}, "$new is aliased to $old");
+}
ok( exists $Config{cc}, "has cc");
End of Patch.