From: Michael G. Schwern Date: Mon, 2 Sep 2002 22:29:07 +0000 (-0700) Subject: test grandfathered Config variables X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=d10bb151b5056823b95b3611bf997c4ddfae0f57;p=p5sagit%2Fp5-mst-13.2.git test grandfathered Config variables Message-ID: <20020903052907.GR8061@ool-18b93024.dyn.optonline.net> p4raw-id: //depot/perl@17837 --- diff --git a/lib/Config.t b/lib/Config.t index afc3c4a..4678769 100644 --- a/lib/Config.t +++ b/lib/Config.t @@ -4,7 +4,7 @@ BEGIN { require "./test.pl"; } -plan tests => 23; +plan tests => 29; use_ok('Config'); @@ -16,6 +16,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"); ok( exists $Config{ccflags}, "has ccflags");