mirror of
https://github.com/odoo/runbot.git
synced 2025-03-27 13:25:47 +07:00
Do not compute badge for skipped and display warning badge
This commit is contained in:
parent
ad834107c3
commit
50565224b5
@ -918,6 +918,7 @@ class RunbotController(http.Controller):
|
|||||||
('branch_id.branch_name', '=', branch),
|
('branch_id.branch_name', '=', branch),
|
||||||
('branch_id.sticky', '=', True),
|
('branch_id.sticky', '=', True),
|
||||||
('state', 'in', ['testing', 'running', 'done']),
|
('state', 'in', ['testing', 'running', 'done']),
|
||||||
|
('result', '!=', 'skipped'),
|
||||||
]
|
]
|
||||||
|
|
||||||
last_update = '__last_update'
|
last_update = '__last_update'
|
||||||
@ -940,8 +941,13 @@ class RunbotController(http.Controller):
|
|||||||
state = 'testing'
|
state = 'testing'
|
||||||
cache_factor = 1
|
cache_factor = 1
|
||||||
else:
|
else:
|
||||||
state = 'success' if build['result'] == 'ok' else 'failed'
|
|
||||||
cache_factor = 2
|
cache_factor = 2
|
||||||
|
if build['result'] == 'ok':
|
||||||
|
state = 'success'
|
||||||
|
elif build['result'] == 'warn':
|
||||||
|
state = 'warning'
|
||||||
|
else:
|
||||||
|
state = 'failed'
|
||||||
|
|
||||||
# from https://github.com/badges/shields/blob/master/colorscheme.json
|
# from https://github.com/badges/shields/blob/master/colorscheme.json
|
||||||
color = {
|
color = {
|
||||||
|
Loading…
Reference in New Issue
Block a user