Commit 2b3b9a3c authored by Mehmet Emin INAC's avatar Mehmet Emin INAC

Fix deprecation warning about quoting AR objects

The below deprecation warning says 6.2. but it's been postponed to 7.0.
already;

```
DEPRECATION WARNING: Passing an Active Record object to `quote`
directly is deprecated and will be no longer quoted as id value in
Rails 6.2.
```
parent 91b16296
......@@ -23,7 +23,7 @@ RSpec.describe Gitlab::ObjectHierarchy do
end
it 'can find ancestors upto a certain level' do
relation = described_class.new(Group.where(id: child2), options: options).base_and_ancestors(upto: child1)
relation = described_class.new(Group.where(id: child2), options: options).base_and_ancestors(upto: child1.id)
expect(relation).to contain_exactly(child2)
end
......@@ -143,7 +143,7 @@ RSpec.describe Gitlab::ObjectHierarchy do
end
it 'can find ancestors upto a certain level' do
relation = described_class.new(Group.where(id: child2), options: options).ancestors(upto: child1)
relation = described_class.new(Group.where(id: child2), options: options).ancestors(upto: child1.id)
expect(relation).to be_empty
end
......
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