#277 ✓resolved
Jonathan Hicks

Selenium tests not working after 0.5.0 upgrade

Reported by Jonathan Hicks | August 13th, 2009 @ 01:41 PM

After upgrading to version 0.5.0 my selenium tests stopped working. Now I get the error:

undefined method get' for #<Webrat::SeleniumSession:0xb24f044> (NoMethodError) (eval):2:invisit' ./features/step_definitions/webrat_steps.rb:11:in `/^I go to (.+)$/'

The step definition is:
When /^I go to (.+)$/ do |page_name|
visit path_to(page_name) end

This is what is in my cucumber env.rb file:

require 'webrat'
require 'webrat/core/matchers'

Webrat.configure do |config|
config.mode = :selenium end

Comments and changes to this ticket

  • Adam

    Adam August 14th, 2009 @ 06:55 PM

    We were also hit by this but it was our first experience with selenium & cucumber so we were quite confused on whether it was config issue or webrat issue.

    It seems there was a refactoring of the Webrat::Session that introduced a webrat_adapter. What seemed to be happening was that in selenium mode it would call visit on the Webrat::Session instead of the SeleniumSession. Webrat::Session would try and delegate the 'get' call to the underlying SeleniumSession adapter that would not have this method defined.

    It should have been calling visit on SeleniumSession instead of on Webrat::Session.

  • Bryan Helmkamp

    Bryan Helmkamp August 18th, 2009 @ 12:29 AM

    Thanks for the report, guys. I'll try to track this down tomorrow and get it resolved ASAP.

    Cheers,

    -Bryan

  • Bryan Helmkamp

    Bryan Helmkamp August 18th, 2009 @ 12:44 AM

    • State changed from “new” to “resolved”

    This is resolved in master. I cut a new 0.5.1 release with the fix. Please let me know if you have any further problems.

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

Ruby Acceptance Testing for Web applications.

Shared Ticket Bins

Pages