It's probably a two-step process if you don't want to hard-code index names:

  indices = 
ThinkingSphinx::Configuration.instance.indices_for_references(*references)
  ThinkingSphinx::Test.index *indices.collect(&:name)

Each index's reference is the first argument to ThinkingSphinx::Index.define - 
so, usually the model name in lowercase and underscored, as a symbol. So, you 
could be passing just :article or :user to indices_for_references.

On 07/08/2013, at 3:34 AM, Daniel Vandersluis wrote:

> Is there any equivalent to Model.sphinx_index_names in TS3? How can I tell TS 
> to just index a given model (in test)?
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Thinking Sphinx" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at http://groups.google.com/group/thinking-sphinx.
> For more options, visit https://groups.google.com/groups/opt_out.
>  
>  

-- 
You received this message because you are subscribed to the Google Groups 
"Thinking Sphinx" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/thinking-sphinx.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to