summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--t/data/rpm-v3/KBackup-1.2.11-1.src.rpmbin0 -> 110893 bytes
-rw-r--r--t/superuser--media_info_dir.t12
2 files changed, 12 insertions, 0 deletions
diff --git a/t/data/rpm-v3/KBackup-1.2.11-1.src.rpm b/t/data/rpm-v3/KBackup-1.2.11-1.src.rpm
new file mode 100644
index 00000000..09057446
--- /dev/null
+++ b/t/data/rpm-v3/KBackup-1.2.11-1.src.rpm
Binary files differ
diff --git a/t/superuser--media_info_dir.t b/t/superuser--media_info_dir.t
index 2f233ee9..6ce19af9 100644
--- a/t/superuser--media_info_dir.t
+++ b/t/superuser--media_info_dir.t
@@ -37,4 +37,16 @@ sub rpm_v3 {
is(`rpm -qa --root $::pwd/root`, '');
urpmi_removemedia($medium_name);
}
+
+ foreach my $src_rpm (glob('media/rpm-v3/*.rpm')) {
+ my ($wanted_arch) = $src_rpm =~ /(\w+)\.rpm$/;
+ my $cmd = urpm_cmd('urpmq') . " -f $src_rpm";
+ warn "# $cmd\n";
+ chomp(my $fullname = `$cmd`);
+ my ($arch) = $fullname =~ /(\w+)$/;
+
+ $wanted_arch = 'i386' if $src_rpm =~ /KBackup/; # ERROR: package has a Sourcerpm empty tag (#29809)
+
+ is($arch, $wanted_arch, "$fullname should have arch $wanted_arch (found $arch)");
+ }
}