diff options
author | Robert Speicher <rspeicher@gmail.com> | 2017-04-10 18:32:30 -0400 |
---|---|---|
committer | Robert Speicher <rspeicher@gmail.com> | 2017-04-10 18:32:30 -0400 |
commit | add1c188603ac4f9f895e5cb84a48ebc1deee394 (patch) | |
tree | ec0d869ddfcc197c6b0799dccefa7d89793f2974 | |
parent | 9c576cc7e9414e64b4aac0544615e7d5e92c3558 (diff) | |
download | gitlab-ce-add1c188603ac4f9f895e5cb84a48ebc1deee394.tar.gz |
Remove an unused `Issue.open_for` scope
-rw-r--r-- | app/models/issue.rb | 1 | ||||
-rw-r--r-- | spec/models/issue_spec.rb | 9 |
2 files changed, 0 insertions, 10 deletions
diff --git a/app/models/issue.rb b/app/models/issue.rb index d8d9db477d2..889f91d87ba 100644 --- a/app/models/issue.rb +++ b/app/models/issue.rb @@ -27,7 +27,6 @@ class Issue < ActiveRecord::Base validates :project, presence: true scope :cared, ->(user) { where(assignee_id: user) } - scope :open_for, ->(user) { opened.assigned_to(user) } scope :in_projects, ->(project_ids) { where(project_id: project_ids) } scope :without_due_date, -> { where(due_date: nil) } diff --git a/spec/models/issue_spec.rb b/spec/models/issue_spec.rb index 4bdd46a581d..d057c9cf6e9 100644 --- a/spec/models/issue_spec.rb +++ b/spec/models/issue_spec.rb @@ -134,15 +134,6 @@ describe Issue, models: true do end end - describe '#is_being_reassigned?' do - it 'returns issues assigned to user' do - user = create(:user) - create_list(:issue, 2, assignee: user) - - expect(Issue.open_for(user).count).to eq 2 - end - end - describe '#closed_by_merge_requests' do let(:project) { create(:project, :repository) } let(:issue) { create(:issue, project: project)} |