This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Fix to run this test in the core
[perl5.git] / lib / CPAN / t / 03pkgs.t
CommitLineData
554a9ef5
SP
1# test if our own version numbers meet expectations
2
0a78cd5d 3use strict;
c7588fc8 4eval 'use warnings';
4d1321a7 5
4d1321a7
A
6my @m;
7if ($ENV{PERL_CORE}){
8 @m = ("CPAN", map { "CPAN::$_" } qw(Debug FirstTime Nox Tarzip Version));
9} else {
28b6a607 10 opendir DH, "lib/CPAN" or die;
4d1321a7
A
11 @m = ("CPAN", map { "CPAN::$_" } grep { s/\.pm$// } readdir DH);
12}
554a9ef5
SP
13
14use Test::More;
f3fe0ae6 15plan(tests => scalar @m);
554a9ef5
SP
16
17for my $m (@m) {
0a78cd5d 18 local $^W = 0;
554a9ef5
SP
19 eval "require $m";
20 ok($m->VERSION >= 1.76, sprintf "%20s: %s", $m, $m->VERSION);
21}
22
23# Local Variables:
24# mode: cperl
25# cperl-indent-level: 2
26# End: