Skip to content

Commit 19c9a08

Browse files
Leontbingos
authored andcommitted
Add missing DISTVNAME to otherwise failing tests
1 parent 8549ed3 commit 19c9a08

File tree

2 files changed

+13
-9
lines changed

2 files changed

+13
-9
lines changed

t/meta_convert.t

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,32 +16,33 @@ chdir $tmpdir or die "chdir $tmpdir: $!";
1616
my $EMPTY = qr/['"]?version['"]?\s*:\s*['"]['"]/;
1717
my @DATA = (
1818
[
19-
[ DISTNAME => 'Net::FTP::Recursive', VERSION => 'Recursive.pm', ],
19+
[ DISTNAME => 'Net-FTP-Recursive', VERSION => 'Recursive.pm', ],
2020
qr{Can't parse version 'Recursive.pm'},
2121
'VERSION => filename',
2222
$EMPTY,
2323
],
2424
[
25-
[ DISTNAME => 'Image::Imgur', VERSION => 'undef', ],
25+
[ DISTNAME => 'Image-Imgur', VERSION => 'undef', ],
2626
qr{Can't parse version 'undef'},
2727
'no $VERSION in file -> VERSION=>"undef"',
2828
$EMPTY,
2929
],
3030
[
31-
[ DISTNAME => 'SQL::Library', VERSION => 0.0.3, ],
31+
[ DISTNAME => 'SQL-Library', VERSION => 0.0.3, ],
3232
qr{Can't parse version '\x00\x00\x03'},
3333
"x.y.z version",
3434
$EMPTY,
3535
],
3636
[
37-
[ DISTNAME => 'Array::Suffix', VERSION => '.5', ],
37+
[ DISTNAME => 'Array-Suffix', VERSION => '.5', ],
3838
qr{Can't parse version '.5'},
3939
".5 version",
4040
$EMPTY,
4141
],
4242
[
4343
[
44-
DISTNAME => 'Attribute::Signature',
44+
DISTNAME => 'Attribute-Signature',
45+
DISTVNAME => 'Attribute-Signature-1.23.tar.gz',
4546
META_MERGE => {
4647
resources => {
4748
repository => 'http://github.com/chorny/Attribute-Signature',
@@ -55,7 +56,8 @@ my @DATA = (
5556
],
5657
[
5758
[
58-
DISTNAME => 'CPAN::Testers::ParseReport',
59+
DISTNAME => 'CPAN-Testers-ParseReport',
60+
DISTVNAME => 'CPAN-Testers-ParseReport-2.34.tar.gz',
5961
VERSION => '2.34',
6062
META_ADD => {
6163
provides => {
@@ -72,7 +74,7 @@ my @DATA = (
7274
],
7375
[
7476
[
75-
DISTNAME => 'Bad::License',
77+
DISTNAME => 'Bad-License',
7678
VERSION => '2.34',
7779
LICENSE => 'death and retribution',
7880
],

t/metafile_data.t

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,9 @@ sub mymeta_ok {
3535
}
3636

3737
my $new_mm = sub {
38-
return bless { ARGS => {@_}, @_ }, 'ExtUtils::MM_Any';
38+
my %args = @_;
39+
$args{DISTVNAME} ||= "$args{DISTNAME}-$args{VERSION}.tar.gz";
40+
return bless { ARGS => \%args, %args }, 'ExtUtils::MM_Any';
3941
};
4042
my @METASPEC14 = (
4143
'meta-spec' => {
@@ -456,7 +458,7 @@ my @GENERIC_OUT = (
456458
note "CPAN::Meta bug using the module version instead of the meta spec version";
457459
{
458460
my $mm = $new_mm->(
459-
NAME => 'GD::Barcode::Code93',
461+
DISTNAME => 'GD-Barcode-Code93',
460462
AUTHOR => 'Chris DiMartino',
461463
ABSTRACT => 'Code 93 implementation of GD::Barcode family',
462464
PREREQ_PM => {

0 commit comments

Comments
 (0)