Is there a way to reliably test the acts_as_ferret plugin using RoR
functional tests? I load my fixtures and no matter what I do, the test
won''t return a result for what *should* be a query that returns
results.
Any help on this would be greatly appreciated.
FIXTURE
********
article_001:
id: 1
title: some valid article title
body: This is a valid article entry with
some images and stuff.
FUNCTIONAL TEST
******************
def test_search
get :search, :q => "some valid article title"
assert_equal 1, assigns(:articles).size
end
MODEL
*******
acts_as_ferret( { :fields => { ''title'' => { :boost
=> 2 },
''body'' => { :boost =>
1.5 },
''ferret_index_article_comments'' => {
:boost => 1 },
''ferret_index_article_image_captions''
=> { :boost => 1.5 } } },
{ :analyzer =>
Ferret::Analysis::StandardAnalyzer.new([nil]) } )
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---