无法在导轨3中加载'firewatir'宝石

时间:2011-03-24 06:38:53

标签: ruby-on-rails-3 watir firewatir

我想在rails 3控制器中运行cucumber命令,但我将'gem firewatir'添加到gemfile, 当我'rails server'时,我收到了这个错误,页面显示“内部服务器错误”。


[2011-03-24 14:32:05] INFO  WEBrick 1.3.1
[2011-03-24 14:32:05] INFO  ruby 1.8.7 (2009-06-12) [universal-darwin10.0]
[2011-03-24 14:32:05] INFO  WEBrick::HTTPServer#start: pid=91734 port=3000
[2011-03-24 14:32:06] ERROR NoMethodError: undefined method `cache' for :active_support:Symbol
    /Library/Ruby/Gems/1.8/gems/activesupport-3.0.5/lib/active_support/cache/strategy/local_cache.rb:74:in `call'
    /Library/Ruby/Gems/1.8/gems/rack-1.2.2/lib/rack/lock.rb:11:in `call'
    /Library/Ruby/Gems/1.8/gems/rack-1.2.2/lib/rack/lock.rb:11:in `synchronize'
    /Library/Ruby/Gems/1.8/gems/rack-1.2.2/lib/rack/lock.rb:11:in `call'
    /Library/Ruby/Gems/1.8/gems/actionpack-3.0.5/lib/action_dispatch/middleware/static.rb:30:in `call'
    /Library/Ruby/Gems/1.8/gems/railties-3.0.5/lib/rails/application.rb:168:in `call'
    /Library/Ruby/Gems/1.8/gems/railties-3.0.5/lib/rails/application.rb:77:in `send'
    /Library/Ruby/Gems/1.8/gems/railties-3.0.5/lib/rails/application.rb:77:in `method_missing'
    /Library/Ruby/Gems/1.8/gems/railties-3.0.5/lib/rails/rack/log_tailer.rb:14:in `call'
    /Library/Ruby/Gems/1.8/gems/rack-1.2.2/lib/rack/content_length.rb:13:in `call'
    /Library/Ruby/Gems/1.8/gems/rack-1.2.2/lib/rack/handler/webrick.rb:52:in `service'
    /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/webrick/httpserver.rb:104:in `service'
    /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/webrick/httpserver.rb:65:in `run'
    /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/webrick/server.rb:173:in `start_thread'
    /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/webrick/server.rb:162:in `start'
    /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/webrick/server.rb:162:in `start_thread'
    /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/webrick/server.rb:95:in `start'
    /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/webrick/server.rb:92:in `each'
    /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/webrick/server.rb:92:in `start'
    /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/webrick/server.rb:23:in `start'
    /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/webrick/server.rb:82:in `start'
    /Library/Ruby/Gems/1.8/gems/rack-1.2.2/lib/rack/handler/webrick.rb:13:in `run'
    /Library/Ruby/Gems/1.8/gems/rack-1.2.2/lib/rack/server.rb:213:in `start'
    /Library/Ruby/Gems/1.8/gems/railties-3.0.5/lib/rails/commands/server.rb:65:in `start'
    /Library/Ruby/Gems/1.8/gems/railties-3.0.5/lib/rails/commands.rb:30
    /Library/Ruby/Gems/1.8/gems/railties-3.0.5/lib/rails/commands.rb:27:in `tap'
    /Library/Ruby/Gems/1.8/gems/railties-3.0.5/lib/rails/commands.rb:27
    script/rails:6:in `require'
    script/rails:6

如果我没有将'gem firewatir'添加到gemfile,rails服务器可以运行,但是当运行cucumber命令时,我收到此错误:


no such file to load -- firewatir (LoadError)

有没有人遇到过这个问题,或者谁知道如何修复它?感谢

2 个答案:

答案 0 :(得分:2)

我认为这是一个已知(并且已修复)的问题:Watir and Rails 3.0.X incompatible

答案 1 :(得分:0)

我不确定这是一回事,因为stacktrace不包含来自commonwatir / firewatir的任何行。它可能是不同的东西,但不能肯定地说。