[rspec-users] Trouble making rspec-rails 2 work with webrat.
dchelimsky at gmail.com
Mon Nov 15 18:36:57 EST 2010
On Nov 15, 2010, at 4:51 PM, Peter Havens wrote:
> I'm having problems getting rspec-rails 2 request specs to work with
> webrat. Any help would be appreciated. Here's my setup:
> ruby 1.9.2p0
> rails 3.0.1
> rspec-rails 2.1.0
> webrat 0.7.2
> Here's the error I'm getting:
> $ rspec --backtrace spec/requests/ssl_certificate_requests_spec.rb
> 1) <text>
> Failure/Error: Unable to find matching line from backtrace
> stack level too deep
> # /opt/local/lib/ruby1.9/1.9.1/forwardable.rb:185
> Finished in 0.49825 seconds
> 1 example, 1 failure
> Here are snippets of my files:
> # spec/spec_helper.rb
> # The following is based on some tips from a cucumber-rails ticket:
> require "webrat"
> require "webrat/core/matchers"
> include Rack::Test::Methods
> include Webrat::Methods
> include Webrat::Matchers
> Webrat.configure do |config|
> config.mode = :rack
> config.open_error_files = false
> # spec/requests/<file>_spec.rb
> require "spec_helper"
> describe "<text>" do
> it "<text>" do
> visit <text>_path
> # The following works when uncommented:
> # get <text>_path
> # assert_template '<text>/<text>'
This is actually a webrat issue, but it is reported to rspec-rails and webrat:
> rspec-users mailing list
> rspec-users at rubyforge.org
More information about the rspec-users