diff options
Diffstat (limited to 'scripts/t')
-rw-r--r-- | scripts/t/Dpkg_Arch.t | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/scripts/t/Dpkg_Arch.t b/scripts/t/Dpkg_Arch.t index 525817085..0ef9d1899 100644 --- a/scripts/t/Dpkg_Arch.t +++ b/scripts/t/Dpkg_Arch.t @@ -16,7 +16,7 @@ use strict; use warnings; -use Test::More tests => 16367; +use Test::More tests => 16369; use_ok('Dpkg::Arch', qw(debarch_to_debtuple debarch_to_multiarch debarch_eq debarch_is debarch_is_wildcard @@ -148,9 +148,16 @@ my @arch_ref; @arch_new = debarch_list_parse('amd64 !arm64 linux-i386 !kfreebsd-any'); is_deeply(\@arch_new, \@arch_ref, 'parse valid arch list'); +@arch_ref = qw(amd64 arm64 linux-i386 kfreebsd-any); +@arch_new = debarch_list_parse('amd64 arm64 linux-i386 kfreebsd-any', positive => 1); +is_deeply(\@arch_new, \@arch_ref, 'parse valid positive arch list'); + eval { @arch_new = debarch_list_parse('!amd64!arm64') }; ok($@, 'parse concatenated arches failed'); +eval { @arch_new = debarch_list_parse('amd64 !arm64 !mips', positive => 1) }; +ok($@, 'parse disallowed negated arches failed'); + is(debarch_to_abiattrs(undef), undef, 'undef ABI attrs'); is_deeply([ debarch_to_abiattrs('amd64') ], [ qw(64 little) ], 'amd64 ABI attrs'); |