Don't trigger tests on an arch the triggering package has no binaries for

If reverse-dependencies of this package still exist on the architecture, these
would be captured as uninstallables; we don't need to additionally trigger
tests that can never succeed, would tell us nothing about the package if they
did, and will just cause more work to hint away the results.
master
Steve Langasek 4 years ago
parent 858c47ea26
commit 586083acfa

@ -336,6 +336,15 @@ class AutopkgtestPolicy(BasePolicy):
# we want to test the package itself, if it still has a test in unstable
srcinfo = self.britney.sources['unstable'][src]
test_for_arch = False
for pkg_id in srcinfo.binaries:
if pkg_id.architecture in (arch, 'all'):
test_for_arch = True
# If the source package builds no binaries for this architecture,
# don't try to trigger tests for it.
if not test_for_arch:
return []
if 'autopkgtest' in srcinfo.testsuite or self.has_autodep8(srcinfo, binaries_info):
reported_pkgs.add(src)
tests.append((src, ver))

Loading…
Cancel
Save