English 中文(简体)
Rspec获胜 t ——Error: In `bin_path : can t executpec for rspec-2.0.0.beta.22 (Gem:Exception)
原标题:Rspec won t run - Error: In `bin_path : can t find executable spec for rspec-2.0.0.beta.22 (Gem::Exception)
  • 时间:2010-09-13 07:31:42
  •  标签:
  • rspec

当我从指挥部那里接手时,我会看一看铁路。

光谱

我有以下错误:

/Library/Ruby/Site/1.8/rubygems.rb:335:in `bin_path : can t find executable spec for rspec-2.0.0.beta.22 (Gem::Exception) from /usr/bin/spec:19

然而,在我执政时,我却在任满。

$ 谱

测试是罚款的。

问题是什么?

最佳回答

<代码>spec/code>的指挥改名为rspec in 2.0。 由于1.x 宝石仍在贵方体系中,当你在宝石中注明2.x时,它只是由Bundler“隐藏的”。

问题回答

对于那些从事已经过时的项目的人来说,你可以通过这样做来纠正这一错误:

which spec

然后向贵方档案编辑开放,修改第11条,看上去。

version =  >= 0 

To

version =  < 2 

你们的幽灵将再次努力:

Run $ rspec spec/

not $ spec spec/





相关问题
How to use rspec to test named routes?

Given I have a named route: map.some_route /some_routes/:id , :controller => some , :action => other How do I use the routing spec file spec/routing/some_routing_spec.rb to test for that ...

Silencing Factory Girl logging

Just to clear the air, I am not some cruel factory master trying to silence working ladies. I am having a very annoying problem where when using Thoughtbot s factory girl in my specs, every time ...

Controller specs in isolation mode and render :update

I am using RSpec for writing my controller tests/specs. I faced the problem, that the following code gets rendered: render :update do |page| page[ middle_content ].replace_html :partial => "...

rspec testing views with internationalization?

I want to make sure I have the right meta desc/keyword and title text in my view so I want to create rspec views tests for that. Now the real challange here is how to make it work across multiple ...

热门标签