Christopher Bailey
2008-Jul-25 08:11 UTC
[rspec-users] Webrat visits fails, but works in browser
I''m wondering if folks have suggestions for how I can debug the following problem. I have some RSpec Stories that use WebRat, and do a "visits hotels_path" type of thing. It is failing, yet the page works fine in the browser. I''m trying to figure out how to go about looking into why Webrat fails. The error it puts out looks like: FAILURES: 1) Add and edit hotels (View all hotels) FAILED RuntimeError: Page load was not successful (Code: 0) /Users/chris/Code/project/vendor/plugins/webrat/lib/webrat/core/page.rb:298:in `flunk'' /Users/chris/Code/project/vendor/plugins/webrat/lib/webrat/core/page.rb:268:in `request_page'' /Users/chris/Code/project/vendor/plugins/webrat/lib/webrat/core/page.rb:223:in `load_page'' /Users/chris/Code/project/vendor/plugins/webrat/lib/webrat/core/page.rb:19:in `initialize'' /Users/chris/Code/project/vendor/plugins/webrat/lib/webrat/rails/session.rb:15:in `new'' /Users/chris/Code/project/vendor/plugins/webrat/lib/webrat/rails/session.rb:15:in `visits'' /Library/Ruby/Gems/1.8/gems/actionpack-2.1.0/lib/action_controller/integration.rb:501:in `send!'' /Library/Ruby/Gems/1.8/gems/actionpack-2.1.0/lib/action_controller/integration.rb:501:in `method_missing'' /Users/chris/Code/project/stories/steps/hotel_steps.rb:37:in `view all hotels'' stories/all.rb:2 I''m using the very latest webrat (was also using a version from several weeks ago and this happened too, so I updated to see if that made a difference). Any suggestions welcome, thanks. -- Christopher Bailey Cobalt Edge LLC http://cobaltedge.com
Bart Zonneveld
2008-Jul-25 12:56 UTC
[rspec-users] Webrat visits fails, but works in browser
On 25 jul 2008, at 10:11, Christopher Bailey wrote:> I''m wondering if folks have suggestions for how I can debug the > following problem. I have some RSpec Stories that use WebRat, and do > a "visits hotels_path" type of thing. It is failing, yet the page > works fine in the browser. I''m trying to figure out how to go about > looking into why Webrat fails. The error it puts out looks like:<snip> Just look in yout log/test.log. That usually has a lot more info than the output from webrat. good luck, bartz
Christopher Bailey
2008-Jul-25 14:48 UTC
[rspec-users] Webrat visits fails, but works in browser
Ok, thanks. I have figured it out of course by now :) It was an issue with RedCloth. On Fri, Jul 25, 2008 at 5:56 AM, Bart Zonneveld <loop at superinfinite.com> wrote:> > On 25 jul 2008, at 10:11, Christopher Bailey wrote: > >> I''m wondering if folks have suggestions for how I can debug the >> following problem. I have some RSpec Stories that use WebRat, and do >> a "visits hotels_path" type of thing. It is failing, yet the page >> works fine in the browser. I''m trying to figure out how to go about >> looking into why Webrat fails. The error it puts out looks like: > > <snip> > > Just look in yout log/test.log. That usually has a lot more info than the > output from webrat. > > good luck, > bartz > > _______________________________________________ > rspec-users mailing list > rspec-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users >-- Christopher Bailey Cobalt Edge LLC http://cobaltedge.com