summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorDouwe Maan <douwe@gitlab.com>2017-06-29 14:28:16 +0000
committerDouwe Maan <douwe@gitlab.com>2017-06-29 14:28:16 +0000
commit2c879643219fdba20681bfcdd8b12d66fd2aef84 (patch)
tree3631e4e6a1508676844728eb349f2d1fdbf16e17 /spec
parent3d49246dc8cd28555f7c06608fc75dcd37ee1b08 (diff)
parenta3d7983b18cc81607c255f64b678da0ab7b9477d (diff)
downloadgitlab-ce-2c879643219fdba20681bfcdd8b12d66fd2aef84.tar.gz
Merge branch 'revert-12499' into 'master'
Revert "Merge branch 'dm-drop-default-scope-on-sortable-finders' into 'master'" Closes #34511 See merge request !12557
Diffstat (limited to 'spec')
-rw-r--r--spec/models/concerns/sortable_spec.rb21
1 files changed, 0 insertions, 21 deletions
diff --git a/spec/models/concerns/sortable_spec.rb b/spec/models/concerns/sortable_spec.rb
deleted file mode 100644
index d1e17c4f684..00000000000
--- a/spec/models/concerns/sortable_spec.rb
+++ /dev/null
@@ -1,21 +0,0 @@
-require 'spec_helper'
-
-describe Sortable do
- let(:relation) { Issue.all }
-
- describe '#where' do
- it 'orders by id, descending' do
- order_node = relation.where(iid: 1).order_values.first
- expect(order_node).to be_a(Arel::Nodes::Descending)
- expect(order_node.expr.name).to eq(:id)
- end
- end
-
- describe '#find_by' do
- it 'does not order' do
- expect(relation).to receive(:unscope).with(:order).and_call_original
-
- relation.find_by(iid: 1)
- end
- end
-end