summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorJasper Maes <jaspermaes.jm@gmail.com>2018-11-17 16:14:36 +0100
committerJasper Maes <jaspermaes.jm@gmail.com>2018-11-17 16:14:36 +0100
commit5d5481519deb304243ed1c09171ccf8a45052d46 (patch)
tree88230bf396d2cfa9afdda5b22ed0eacb497d2392 /spec
parent29d8179ba07be3ed111f939285eb4064d84cb7df (diff)
downloadgitlab-ce-5d5481519deb304243ed1c09171ccf8a45052d46.tar.gz
Rails5: Passing a class as a value in an Active Record query is deprecated
Diffstat (limited to 'spec')
-rw-r--r--spec/finders/pending_todos_finder_spec.rb2
-rw-r--r--spec/models/todo_spec.rb2
2 files changed, 2 insertions, 2 deletions
diff --git a/spec/finders/pending_todos_finder_spec.rb b/spec/finders/pending_todos_finder_spec.rb
index 32fad5e225f..b41b1b46a93 100644
--- a/spec/finders/pending_todos_finder_spec.rb
+++ b/spec/finders/pending_todos_finder_spec.rb
@@ -46,7 +46,7 @@ describe PendingTodosFinder do
create(:todo, :pending, user: user, target: note)
- todos = described_class.new(user, target_type: issue.class).execute
+ todos = described_class.new(user, target_type: issue.class.name).execute
expect(todos).to eq([todo])
end
diff --git a/spec/models/todo_spec.rb b/spec/models/todo_spec.rb
index 2c01578aaca..82ff2a002e0 100644
--- a/spec/models/todo_spec.rb
+++ b/spec/models/todo_spec.rb
@@ -226,7 +226,7 @@ describe Todo do
create(:todo, target: create(:merge_request))
- expect(described_class.for_type(Issue)).to eq([todo])
+ expect(described_class.for_type(Issue.name)).to eq([todo])
end
end