运行Heckle时出错? `current_code':Ruby2Ruby的未定义方法`translate' [英] Error running Heckle? `current_code': undefined method `translate' for Ruby2Ruby

查看:89
本文介绍了运行Heckle时出错? `current_code':Ruby2Ruby的未定义方法`translate'的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试运行Heckle,但不断出现错误:

I'm trying to run Heckle, and I keep getting an error:

> spec spec/controllers/my_controller_spec.rb --heckle MyController

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!! exception= has a thick skin. There's nothing to heckle.
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

(Runs through several mutations...)

/home/developer/.gem/ruby/1.8/gems/heckle-1.4.3/lib/heckle.rb:603:in `current_code': undefined method `translate' for Ruby2Ruby:Class (NoMethodError)

有什么想法吗?

编辑:我忘记了gem版本:

EDIT: I forgot the gem versions:

heckle (1.4.3)
ruby2ruby (1.2.3)
rails (2.3.2, 2.2.2)
rspec (1.2.6)
rspec-rails(1.2.6, 1.1.12)

推荐答案

安装ruby2ruby 1.2.2. 1.2.3中似乎对API进行了更改.

Install ruby2ruby 1.2.2. There seems to be an API change in 1.2.3.

只需为 1.2.2 看上去类方法"translate"已被完全删除,尽管文档并未反映出这种情况

Looks like the class method 'translate' has been totally removed, although the docs don't reflect this

这篇关于运行Heckle时出错? `current_code':Ruby2Ruby的未定义方法`translate'的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆