我在ruby 1.8.7和rvm下运行了一个Rails 2.3.4应用程序,它有一个自定义的gemset。
在尝试启动和运行rspec的过程中,我多次尝试卸载rspec 2并安装rspec和rspec-rails版本1.3.4。然而,当我运行rspec -v时,不管我做什么,我都会得到2.10.0。
最后,我得到了这个错误信息:
You are running rspec-2, but it seems as though rspec-1 has been loaded as
well. This is likely due to a statement like this somewhere in the specs:
require 'spec'
Please locate that statement, remove it, and try again.所以看起来2.10.0实际上还在加载。即使我这样做了,gem uninstall rspec rspec仍然是加载的。到底怎么回事?
发布于 2012-05-23 01:47:26
您应该使用spec ( RSpec 1可执行文件),而不是rspec,如this answer中所述。
https://stackoverflow.com/questions/10705838
复制相似问题