collectiveidea/sunspot_test — Issue #10: Solr fails to start on Rails 3.1.0
Author: rhymes
Created: 2011-11-14 08:41:13+00:00
State: open

I'm using Rails 3.1.0, sunspot 1.2.1 and sunspot_test 0.4.0 with RSpec 2.6.0.

After setting up the environment and launching a test I get the the following error:

Failure/Error: Unable to find matching line from backtrace
SunspotTest::TimeOutError:
Solr failed to start after 15 seconds
# /usr/lib/ruby/gems/1.9.2/gems/sunspot_test-0.4.0/lib/sunspot_test.rb:65:in `wait_until_solr_starts'
# /usr/lib/ruby/gems/1.9.2/gems/sunspot_test-0.4.0/lib/sunspot_test.rb:34:in `start_sunspot_server'
# /usr/lib/ruby/gems/1.9.2/gems/sunspot_test-0.4.0/lib/sunspot_test.rb:17:in `setup_solr'
# /usr/lib/ruby/gems/1.9.2/gems/sunspot_test-0.4.0/lib/sunspot_test/rspec.rb:9:in `block (2 levels) in '
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/hooks.rb:35:in `instance_eval'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/hooks.rb:35:in `run_in'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/hooks.rb:70:in `block in run_all'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/hooks.rb:70:in `each'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/hooks.rb:70:in `run_all'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/hooks.rb:126:in `run_hook_filtered'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/example_group.rb:206:in `eval_before_alls'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/example_group.rb:261:in `run'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/example_group.rb:263:in `block in run'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/example_group.rb:263:in `map'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/example_group.rb:263:in `run'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/example_group.rb:263:in `block in run'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/example_group.rb:263:in `map'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/example_group.rb:263:in `run'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/command_line.rb:24:in `block (2 levels) in run'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/command_line.rb:24:in `map'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/command_line.rb:24:in `block in run'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/reporter.rb:12:in `report'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/command_line.rb:21:in `run'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/runner.rb:80:in `run_in_process'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/runner.rb:66:in `rescue in run'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/runner.rb:62:in `run'
# /usr/lib/ruby/gems/1.9.2/gems/rspec-core-2.6.4/lib/rspec/core/runner.rb:11:in `block in autorun'

It seems that the test runner does not ping the right server because i see solr start in the list of processes