Subject: | find_perl_module_package() returns category in at least some packages |
$c->find_perl_module_package() returns category in at least some packages:
$ perl /tmp/no-category-in-name.t
1..1
Using cached Contents from Tue Mar 30 16:06:28 2010
not ok 1 - Check that the package name does not contain the category
# Failed test 'Check that the package name does not contain the
category'
# at /tmp/no-category-in-name.t line 13.
# got: 'perl/libconfig-any-perl'
# expected: 'libconfig-any-perl'
# Looks like you failed 1 test of 1.
Subject: | category-in-name.patch |
--- /usr/share/perl5/Debian/AptContents.pm 2010-03-30 16:28:52.000000000 +0200
+++ /tmp/AptContents.pm 2010-03-30 16:29:07.000000000 +0200
@@ -462,6 +462,8 @@
else { return $a cmp $b; } # or 0?
} @matches;
+ @matches = map { s[^perl/][]; $_ } @matches;
+
return Debian::Dependency->new( $matches[0], $version )
if @matches;
Subject: | no-category-in-name.t |
#!/usr/bin/perl
use strict;
use warnings;
use Test::More tests => 1;
use Debian::AptContents;
my $c = Debian::AptContents->new( { homedir => '/tmp/.dh-make-perl' } );
my $dep = $c->find_perl_module_package('Config::Any');
is( $dep->pkg(), 'libconfig-any-perl', 'Check that the package name does not contain the category');