rails命令失败

时间:2013-03-04 12:39:50

标签: ruby-on-rails ruby

我正在关注使用rspec,capybara等覆盖TDD的this tutorial。我将以下内容添加到我的Gemfile中:

group :test, :development do
    gem 'turn'
    gem 'rspec-rails'
    gem 'capybara'
    gem 'guard-rspec'
    gem 'growl_notify'
end

bundle install,现在得到:

juco@jucoiMac ~/Desktop/rails-test $ rails s
    gem install minitest
    /Library/Ruby/Gems/1.8/gems/turn-0.9.6/lib/turn/minitest.rb:9:in `require': no such file to load -- minitest/unit (LoadError)
        from /Library/Ruby/Gems/1.8/gems/turn-0.9.6/lib/turn/minitest.rb:9
        from /Library/Ruby/Gems/1.8/gems/turn-0.9.6/lib/turn.rb:13:in `require'
        from /Library/Ruby/Gems/1.8/gems/turn-0.9.6/lib/turn.rb:13
        from /Library/Ruby/Gems/1.8/gems/bundler-1.2.4/lib/bundler/runtime.rb:68:in `require'
        from /Library/Ruby/Gems/1.8/gems/bundler-1.2.4/lib/bundler/runtime.rb:68:in `require'
        from /Library/Ruby/Gems/1.8/gems/bundler-1.2.4/lib/bundler/runtime.rb:66:in `each'
        from /Library/Ruby/Gems/1.8/gems/bundler-1.2.4/lib/bundler/runtime.rb:66:in `require'
        from /Library/Ruby/Gems/1.8/gems/bundler-1.2.4/lib/bundler/runtime.rb:55:in `each'
        from /Library/Ruby/Gems/1.8/gems/bundler-1.2.4/lib/bundler/runtime.rb:55:in `require'
        from /Library/Ruby/Gems/1.8/gems/bundler-1.2.4/lib/bundler.rb:128:in `require'
        from /Users/juco/Desktop/rails-test/config/application.rb:7
        from /Library/Ruby/Gems/1.8/gems/railties-3.2.12/lib/rails/commands.rb:53:in `require'
        from /Library/Ruby/Gems/1.8/gems/railties-3.2.12/lib/rails/commands.rb:53
        from /Library/Ruby/Gems/1.8/gems/railties-3.2.12/lib/rails/commands.rb:50:in `tap'
        from /Library/Ruby/Gems/1.8/gems/railties-3.2.12/lib/rails/commands.rb:50
        from script/rails:6:in `require'
        from script/rails:6

当我尝试执行包括rails server在内的任何rails命令时。这已经posted before,但未得到答复。

2 个答案:

答案 0 :(得分:1)

turn宝石是最小的。似乎你正在使用rspec,因此你有不兼容性。

答案 1 :(得分:1)

转动宝石版 -

 group :test do
      gem 'turn', '< 0.8.3'
    end

来自:Minitest Error