diff --git a/app/models/commit_status.rb b/app/models/commit_status.rb index 6518f54cdff..44b2c1fb1db 100644 --- a/app/models/commit_status.rb +++ b/app/models/commit_status.rb @@ -29,7 +29,7 @@ class CommitStatus < ActiveRecord::Base end scope :exclude_ignored, -> do - # We want to ignore failed_but_allowed jobs + # We want to ignore failed but allowed to fail jobs where("allow_failure = ? OR status IN (?)", false, all_state_names - [:failed, :canceled, :manual]) end diff --git a/spec/models/commit_status_spec.rb b/spec/models/commit_status_spec.rb index 36533bdd11e..7a6386bb672 100644 --- a/spec/models/commit_status_spec.rb +++ b/spec/models/commit_status_spec.rb @@ -158,7 +158,7 @@ describe CommitStatus, :models do end end - describe '.exclude_ignored' do + describe '.after_stage' do subject { described_class.after_stage(0) } let(:statuses) do