mirror of
https://git.launchpad.net/~ubuntu-release/britney/+git/britney2-ubuntu
synced 2025-04-02 13:51:12 +00:00
Make autopkgtest web site URL an option
This commit is contained in:
parent
1b9fb374a2
commit
acec564443
@ -92,3 +92,5 @@ ADT_SHARED_RESULTS_CACHE =
|
||||
# Swift base URL with the results (must be publicly readable and browsable)
|
||||
# or file location if results are pre-fetched
|
||||
ADT_SWIFT_URL = file:///srv/release.debian.org/britney/state/debci.json
|
||||
# Base URL for autopkgtest site, used for links in the excuses
|
||||
ADT_CI_URL = https://ci.debian.net/
|
||||
|
@ -201,8 +201,7 @@ class AutopkgtestPolicy(BasePolicy):
|
||||
|
||||
# add test result details to Excuse
|
||||
verdict = PolicyVerdict.PASS
|
||||
# TODO: should be generic / an option
|
||||
cloud_url = "http://autopkgtest.ubuntu.com/packages/%(h)s/%(s)s/%(r)s/%(a)s"
|
||||
cloud_url = self.options.adt_ci_url + "packages/%(h)s/%(s)s/%(r)s/%(a)s"
|
||||
for (testsrc, testver) in sorted(pkg_arch_result):
|
||||
arch_results = pkg_arch_result[(testsrc, testver)]
|
||||
r = set([v[0] for v in arch_results.values()])
|
||||
@ -228,7 +227,7 @@ class AutopkgtestPolicy(BasePolicy):
|
||||
'h': srchash(testsrc), 's': testsrc,
|
||||
'r': self.options.series, 'a': arch}
|
||||
if status == 'REGRESSION':
|
||||
retry_url = 'https://autopkgtest.ubuntu.com/request.cgi?' + \
|
||||
retry_url = self.options.adt_ci_url + 'request.cgi?' + \
|
||||
urllib.parse.urlencode([('release', self.options.series),
|
||||
('arch', arch),
|
||||
('package', testsrc),
|
||||
@ -741,7 +740,7 @@ class AutopkgtestPolicy(BasePolicy):
|
||||
result = 'RUNNING'
|
||||
else:
|
||||
result = 'RUNNING-ALWAYSFAIL'
|
||||
url = 'http://autopkgtest.ubuntu.com/running'
|
||||
url = self.options.adt_ci_url + 'running'
|
||||
else:
|
||||
raise RuntimeError('Result for %s/%s/%s (triggered by %s) is neither known nor pending!' %
|
||||
(src, ver, arch, trigger))
|
||||
|
@ -389,6 +389,7 @@ ADT_PPAS =
|
||||
ADT_SHARED_RESULTS_CACHE =
|
||||
|
||||
ADT_SWIFT_URL = http://localhost:18085
|
||||
ADT_CI_URL = https://autopkgtest.ubuntu.com/
|
||||
''')
|
||||
assert os.path.exists(self.britney)
|
||||
|
||||
|
@ -210,13 +210,13 @@ class T(TestBase):
|
||||
self.assertEqual(exc['darkgreen']['policy_info']['autopkgtest'],
|
||||
{'darkgreen': {
|
||||
'amd64': ['RUNNING-ALWAYSFAIL',
|
||||
'http://autopkgtest.ubuntu.com/running',
|
||||
'http://autopkgtest.ubuntu.com/packages/d/darkgreen/testing/amd64',
|
||||
'https://autopkgtest.ubuntu.com/running',
|
||||
'https://autopkgtest.ubuntu.com/packages/d/darkgreen/testing/amd64',
|
||||
None,
|
||||
None],
|
||||
'i386': ['RUNNING-ALWAYSFAIL',
|
||||
'http://autopkgtest.ubuntu.com/running',
|
||||
'http://autopkgtest.ubuntu.com/packages/d/darkgreen/testing/i386',
|
||||
'https://autopkgtest.ubuntu.com/running',
|
||||
'https://autopkgtest.ubuntu.com/packages/d/darkgreen/testing/i386',
|
||||
None,
|
||||
None]},
|
||||
'verdict': 'PASS'})
|
||||
@ -499,7 +499,7 @@ class T(TestBase):
|
||||
self.assertEqual(exc['green']['policy_info']['autopkgtest']['lightgreen/1']['amd64'][:4],
|
||||
['REGRESSION',
|
||||
'http://localhost:18085/autopkgtest-testing/testing/amd64/l/lightgreen/20150101_100101@/log.gz',
|
||||
'http://autopkgtest.ubuntu.com/packages/l/lightgreen/testing/amd64',
|
||||
'https://autopkgtest.ubuntu.com/packages/l/lightgreen/testing/amd64',
|
||||
None])
|
||||
|
||||
# should have retry link for the regressions (not a stable URL, test
|
||||
@ -2217,12 +2217,12 @@ class T(TestBase):
|
||||
self.assertEqual(exc['lightgreen']['policy_info']['autopkgtest'],
|
||||
{'lightgreen': {
|
||||
'amd64': ['RUNNING-ALWAYSFAIL',
|
||||
'http://autopkgtest.ubuntu.com/running',
|
||||
'https://autopkgtest.ubuntu.com/running',
|
||||
None,
|
||||
None,
|
||||
None],
|
||||
'i386': ['RUNNING-ALWAYSFAIL',
|
||||
'http://autopkgtest.ubuntu.com/running',
|
||||
'https://autopkgtest.ubuntu.com/running',
|
||||
None,
|
||||
None,
|
||||
None]},
|
||||
@ -2438,7 +2438,7 @@ class T(TestBase):
|
||||
link = urllib.parse.urlparse(exc['green']['policy_info']['autopkgtest']['lightgreen/1']['amd64'][1])
|
||||
self.assertEqual(link.path, os.path.join(debci_file, 'autopkgtest-testing/testing/amd64/l/lightgreen/20170917_101001/log.gz'))
|
||||
self.assertEqual(exc['green']['policy_info']['autopkgtest']['lightgreen/1']['amd64'][2:4],
|
||||
['http://autopkgtest.ubuntu.com/packages/l/lightgreen/testing/amd64',
|
||||
['https://autopkgtest.ubuntu.com/packages/l/lightgreen/testing/amd64',
|
||||
None])
|
||||
|
||||
# should have retry link for the regressions (not a stable URL, test
|
||||
|
Loading…
x
Reference in New Issue
Block a user