1
votes

I am using Capybara selenium webdriver in my env.rb I have the following code

Capybara::Selenium::Driver.new(app, :browser => :ff, :resynchronize => false)

when I execute my feature file using cucumber comman e.g cucumber test.feature

I am getting the below error

unknown option: {:resynchronize=>false} (ArgumentError) c:/Ruby193/lib/ruby/gems/1.9.1/gems/selenium-webdriver-2.26.0/lib/selenium/webdriver/firefox/br idge.rb:17:in `initialize'

I am not sure what causes the issue. When I remove :resynchronize => false from the code and have it as below:

 Capybara::Selenium::Driver.new(app, :browser => :ff)

The code works but I need to have resynchronize => false.

1

1 Answers

0
votes

If you read here you will notice that resynchronization was removed 10 months ago due to being unstable. If you want to wait for ajax in your tests you could implement a step like this:

 When /^I wait (\d+) seconds?$/ do |seconds|
    sleep seconds.to_i
 end

And the then call

When I wait 5 seconds
Then I click on "link_1"
# and so on