I would like to write my usual RSpec / Capybara query specifications to test search capabilities with Sunspot and Solr. I was digging, but I can not find how to do it. I have installed sunspot_test gem and verified that the created products exist. Maybe the problem is with indexing? What am I missing?
require 'spec_helper' describe "search" do context "when searching by name/description" do let!(:super_mario_bros_3) { Factory(:product, :name => 'Super Mario Bros. 3') } let!(:legend_of_zelda) { Factory(:product, :name => 'Legend of Zelda') } before { Product.reindex; Sunspot.commit } it "should only find games matching the search text", :js => true, :search => true do
source share