Commit ee3a0ed6 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

yellow jenkins -> failed build

Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent d72cc7fc
......@@ -72,7 +72,7 @@ class JenkinsService < CiService
if response.code == 200
# img.build-caption-status-icon for old jenkins version
src = Nokogiri.parse(response).css('img.build-caption-status-icon,.build-caption>img').first.attributes['src'].value
if src =~ /(blue\.png|yellow\.png)$/
if src =~ /blue\.png$/
'success'
elsif src =~ /(red|aborted|yellow)\.png$/
'failed'
......
......@@ -45,7 +45,7 @@ eos
end
describe :commit_status do
statuses = {'blue.png' => 'success', 'yellow.png' => 'success', 'red.png' => 'failed', 'aborted.png' => 'failed', 'blue-anime.gif' => 'running', 'grey.png' => 'pending'}
statuses = {'blue.png' => 'success', 'yellow.png' => 'failed', 'red.png' => 'failed', 'aborted.png' => 'failed', 'blue-anime.gif' => 'running', 'grey.png' => 'pending'}
statuses.each do |icon, state|
it "should have a status of #{state} when the icon #{icon} exists." do
stub_request(:get, "http://jenkins.gitlab.org/projects/2/scm/bySHA1/2ab7834c").to_return(status: 200, body: status_body_for_icon(icon), headers: {})
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment