Sha256: 2231c274f251f6da99c31501fa63fe996aa9d99bc24cc7381eca5206c787a555
Contents?: true
Size: 656 Bytes
Versions: 15
Compression:
Stored size: 656 Bytes
Contents
require 'acceptance/spec_helper' describe 'Executing multiple searches in one Sphinx call', :live => true do it "returns results matching the given queries" do pancakes = Article.create! :title => 'Pancakes' waffles = Article.create! :title => 'Waffles' index batch = ThinkingSphinx::BatchedSearch.new batch.searches << Article.search('pancakes') batch.searches << Article.search('waffles') batch.populate batch.searches.first.should include(pancakes) batch.searches.first.should_not include(waffles) batch.searches.last.should include(waffles) batch.searches.last.should_not include(pancakes) end end
Version data entries
15 entries across 15 versions & 1 rubygems