无法找到' run_loop'的版本激活(Gem :: LoadError)

时间:2016-07-26 08:48:41

标签: ruby rubygems cucumber calabash calabash-ios

在执行任何执行功能文件的黄瓜命令期间,我在Calabash-IOS中得到以下提到的错误。

  

无法找到' run_loop'的版本激活(Gem :: LoadError)

我正在使用下面给出的宝石版本 -

command_runner_ng (0.1.0)
cucumber (2.4.0, 1.3.20)
cucumber-core (1.5.0)
cucumber-wire (0.0.1)

calabash-cucumber (0.19.2, 0.12.3)

谢谢

2 个答案:

答案 0 :(得分:2)

这是因为黄瓜的多个版本。卸载黄瓜并重新安装再次解决问题。

$ gem uninstall cucumber

$ gem install cucumber

答案 1 :(得分:0)

运行gem dependency --remote calabash-cucumber会显示相当广泛的依赖项列表:

Gem calabash-cucumber-0.19.2:
  awesome_print (>= 0)
  bundler (~> 1.3)
  clipboard (~> 1.0)
  cucumber (>= 0)
  edn (< 2.0, >= 1.0.6)
  geocoder (< 2.0, >= 1.1.8)
  growl (>= 0, development)
  guard-bundler (>= 0, development)
  guard-rspec (>= 0, development)
  httpclient (< 3.0, >= 2.3.2)
  json (>= 0)
  listen (= 3.0.6, development)
  luffa (>= 1.1.0, development)
  oj (~> 2.0, development)
  pry (>= 0, development)
  pry-nav (>= 0, development)
  rake (= 10.5.0, development)
  redcarpet (= 3.2.0, development)
  rspec (>= 0, development)
  rspec_junit_formatter (>= 0, development)
  run_loop (< 3.0, >= 2.1.3)
  slowhandcuke (~> 0.0.3)
  stub_env (>= 0, development)
  yard (~> 0.8, development)

从底部开始,对于您正在使用的葫芦黄瓜版本,run_loop似乎需要至少2.1.3且小于3.0。我建议您首先验证是否安装了适当的版本。尝试运行:

gem list run_loop

如果安装的版本在列出的版本范围内,那么您可能使用的其他一个宝石(包括gem的依赖项)可能具有不同或更具体的要求。我不知道一个很好的方法来自动检查(没有编写一个简短的Ruby程序来做一些创造性的grepping),但是在你需要的主要宝石上探索是很有可能发现问题

相关问题