diff options
author | Nicholas Clark <nick@ccl4.org> | 2010-10-05 07:32:21 +0100 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2010-10-05 13:48:40 +0100 |
commit | cde5101a7be11e27127dc4c214d749bb2cc993e6 (patch) | |
tree | 2025e59f77db901cb47c4099f3761f2978ce1de3 /t/porting | |
parent | bf07e08f68b96c7832e17dd5eb4eb32618be88d2 (diff) | |
download | perl-cde5101a7be11e27127dc4c214d749bb2cc993e6.tar.gz |
Move pod2usage.PL, podchecker.PL, podselect.PL into cpan/Pod-Parser/scripts
Let ExtUtils::MakeMaker deal with running these extraction scripts, rather than
repeating the logic in (at least) 5 places.
Diffstat (limited to 't/porting')
-rw-r--r-- | t/porting/dual-life.t | 19 |
1 files changed, 15 insertions, 4 deletions
diff --git a/t/porting/dual-life.t b/t/porting/dual-life.t index 9fb780278d..3ec88af5a6 100644 --- a/t/porting/dual-life.t +++ b/t/porting/dual-life.t @@ -16,13 +16,19 @@ use File::Spec::Functions; # Exceptions are found in dual-life bin dirs but aren't # installed by default -my @exceptions = qw( +my @not_installed = qw( ../cpan/Encode/bin/ucm2table ../cpan/Encode/bin/ucmlint ../cpan/Encode/bin/ucmsort ../cpan/Encode/bin/unidump ); +my %dist_dir_exe; + +foreach (qw (podchecker podselect pod2usage)) { + $dist_dir_exe{lc "$_.PL"} = "../cpan/Pod-Parser/$_"; +}; + my @programs; find( @@ -36,11 +42,16 @@ find( qw( ../cpan ../dist ../ext ), ); +my $ext = $^O eq 'VMS' ? '.com' : ''; + for my $f ( @programs ) { $f =~ s/\.\z// if $^O eq 'VMS'; - next if qr/(?i:$f)/ ~~ @exceptions; + next if qr/(?i:$f)/ ~~ @not_installed; $f = basename($f); - $f .= '.com' if $^O eq 'VMS'; - ok( -f catfile('..', 'utils', $f), "$f" ); + if(qr/\A(?i:$f)\z/ ~~ %dist_dir_exe) { + ok( -f "$dist_dir_exe{lc $f}$ext", "$f$ext"); + } else { + ok( -f catfile('..', 'utils', "$f$ext"), "$f$ext" ); + } } |