Skip to content

Commit 639e3da

Browse files
miguelffkarmi
authored andcommitted
[MODEL] Fixed a buggy test introduced in elastic#335
Fixes 04e8608 Related: elastic#370
1 parent 538ed46 commit 639e3da

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

elasticsearch-model/test/unit/adapter_mongoid_test.rb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,9 @@ def ids
7676

7777
context "Importing" do
7878
should "implement the __find_in_batches method" do
79-
DummyClassForMongoid.expects(:all).returns([])
79+
relation = mock()
80+
relation.stubs(:no_timeout).returns([])
81+
DummyClassForMongoid.expects(:all).returns(relation)
8082

8183
DummyClassForMongoid.__send__ :extend, Elasticsearch::Model::Adapter::Mongoid::Importing
8284
DummyClassForMongoid.__find_in_batches do; end

0 commit comments

Comments
 (0)