"Mongo ERROR :: OperationFailure" from testing cucumber with rails on mongoid-gridfs

I get this strange error when running the cucumber test:

ERROR Mongo::OperationFailure: Database command 'filemd5' failed: {"errmsg"=>"exception: best guess plan requested, but scan and order required: query: { files_id: ObjectId('4d1abab3a15c84139c00006e') } order: { files_id: 1, n: 1 } choices: { $natural: 1 } ", "code"=>13284, "ok"=>0.0} 

I have a list of similar scenarios where the first script passes, but all the other following scripts fail. I searched for it and I found that there is a problem with indexing. But I'm not sure which request to write. In addition, I can add a request for mango development. I want to make sure that indexing is done in the test too. If anyone has ideas on this, feel free to.

+6
ruby-on-rails mongoid cucumber
source share
1 answer

Perhaps this error does not occur now. one year after

0
source share

All Articles