Timeout :: Selenium / Capybara / Cucumber / Ruby出错

时间:2015-11-03 13:20:06

标签: ruby selenium cucumber capybara

当我们使用Capybara执行黄瓜红宝石中的场景时,我们正面临着问题。在执行了几个场景之后,我们会出现超时错误,无法继续下一个场景。

显示以下错误

Timeout::Error (Timeout::Error)
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/protocol.rb:146:in `rescue in rbuf_fill'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/protocol.rb:140:in `rbuf_fill'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/protocol.rb:122:in `readuntil'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/protocol.rb:132:in `readline'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:2563:in `read_status_line'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:2552:in `read_new'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:1320:in `block in transport_request'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:1317:in `catch'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:1317:in `transport_request'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:1294:in `request'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:1287:in `block in request'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:746:in `start'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:1285:in `request'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/selenium-webdriver-2.37.0/lib/selenium/webdriver/remote/http/default.rb:83:in `response_for'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/selenium-webdriver-2.37.0/lib/selenium/webdriver/remote/http/default.rb:39:in `request'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/selenium-webdriver-2.37.0/lib/selenium/webdriver/remote/http/common.rb:40:in `call'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/selenium-webdriver-2.37.0/lib/selenium/webdriver/remote/bridge.rb:634:in `raw_execute'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/selenium-webdriver-2.37.0/lib/selenium/webdriver/remote/bridge.rb:612:in `execute'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/selenium-webdriver-2.37.0/lib/selenium/webdriver/remote/bridge.rb:361:in `deleteAllCookies'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/selenium-webdriver-2.37.0/lib/selenium/webdriver/common/options.rb:67:in `delete_all_cookies'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/capybara-2.1.0/lib/capybara/selenium/driver.rb:84:in `reset!'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/capybara-2.1.0/lib/capybara/session.rb:77:in `reset!'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/capybara-2.1.0/lib/capybara.rb:245:in `block in reset_sessions!'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/capybara-2.1.0/lib/capybara.rb:245:in `each'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/capybara-2.1.0/lib/capybara.rb:245:in `reset_sessions!'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/capybara-2.1.0/lib/capybara/cucumber.rb:10:in `After'

我们正在使用Capybara 2.1.0版本和Cucumber 1.3.8。

任何想法都将不胜感激!

0 个答案:

没有答案