我正在 Ubuntu 12.04 64bit 上安装带有 bundle install 的工厂女孩并且收到错误
Installing factory_girl (3.3.0) /usr/lib/ruby/vendor_ruby/1.8/rubygems/installer.rb:388:in `ensure_required_ruby_version_met': factory_girl requires Ruby version >= 1.9.2. (Gem::InstallError)
from /usr/lib/ruby/vendor_ruby/1.8/rubygems/installer.rb:156:in `install'
from /usr/lib/ruby/vendor_ruby/bundler/source.rb:101:in `install'
from /usr/lib/ruby/vendor_ruby/bundler/rubygems_integration.rb:78:in `preserve_paths'
from /usr/lib/ruby/vendor_ruby/bundler/source.rb:91:in `install'
from /usr/lib/ruby/vendor_ruby/bundler/installer.rb:58:in `run'
from /usr/lib/ruby/vendor_ruby/bundler/rubygems_integration.rb:93:in `with_build_args'
from /usr/lib/ruby/vendor_ruby/bundler/installer.rb:57:in `run'
from /usr/lib/ruby/vendor_ruby/bundler/spec_set.rb:12:in `each'
from /usr/lib/ruby/vendor_ruby/bundler/spec_set.rb:12:in `each'
from /usr/lib/ruby/vendor_ruby/bundler/installer.rb:49:in `run'
from /usr/lib/ruby/vendor_ruby/bundler/installer.rb:8:in `install'
from /usr/lib/ruby/vendor_ruby/bundler/cli.rb:222:in `install'
from /usr/lib/ruby/vendor_ruby/bundler/vendor/thor/task.rb:22:in `send'
from /usr/lib/ruby/vendor_ruby/bundler/vendor/thor/task.rb:22:in `run'
from /usr/lib/ruby/vendor_ruby/bundler/vendor/thor/invocation.rb:118:in `invoke_task'
from /usr/lib/ruby/vendor_ruby/bundler/vendor/thor.rb:246:in `dispatch'
from /usr/lib/ruby/vendor_ruby/bundler/vendor/thor/base.rb:389:in `start'
from /usr/bin/bundle:13
这是我的 Ruby -v
ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-linux]
我正在使用 RBenv,这是命令的结果:rbenv version
1.9.3-p194 (set by /home/user/.rbenv/version)
这是命令的结果:rbenv 版本
1.9.2-p290
* 1.9.3-p194 (set by /home/user/.rbenv/version)
这是我的 gemfile 中的 factory_girl_rails
group :test do
gem 'factory_girl_rails', '~> 3.3.0'
end
如果您需要查看更多文件,请告诉我,我很乐意发布它们。任何人都知道为什么我