diff options
author | Kamil Trzcinski <ayufan@ayufan.eu> | 2016-12-05 17:52:50 +0100 |
---|---|---|
committer | Kamil Trzcinski <ayufan@ayufan.eu> | 2016-12-06 14:13:21 +0100 |
commit | 260d754ca89c14297e0e360d35d7914d57e290bf (patch) | |
tree | fbfda69e5237326b6e5accd093b8d43d7b88a300 /app/models/commit_status.rb | |
parent | 6d80b94a89cd2151cbf37f6f98f79d23df7fa638 (diff) | |
download | gitlab-ce-260d754ca89c14297e0e360d35d7914d57e290bf.tar.gz |
Fix handling of allowed to failure jobs
Diffstat (limited to 'app/models/commit_status.rb')
-rw-r--r-- | app/models/commit_status.rb | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/app/models/commit_status.rb b/app/models/commit_status.rb index 2a537dc2a13..cf90475f4d4 100644 --- a/app/models/commit_status.rb +++ b/app/models/commit_status.rb @@ -31,14 +31,9 @@ class CommitStatus < ActiveRecord::Base end scope :exclude_ignored, -> do - quoted_when = connection.quote_column_name('when') # We want to ignore failed_but_allowed jobs where("allow_failure = ? OR status IN (?)", - false, all_state_names - [:failed, :canceled]). - # We want to ignore skipped manual jobs - where("#{quoted_when} <> ? OR status <> ?", 'manual', 'skipped'). - # We want to ignore skipped on_failure - where("#{quoted_when} <> ? OR status <> ?", 'on_failure', 'skipped') + false, all_state_names - [:failed, :canceled]) end scope :latest_ordered, -> { latest.ordered.includes(project: :namespace) } |