例如,在https://github.com/cloudfoundry/cloud_controller_ng/blob/aacfd8/spec/unit/controllers/runtime/apps_controller_spec.rb#L17中,我想确定如何解决“get”方法。我知道的最快的方法是转储接收器 .method(:get).source_location,但我不知道接收器在这里。
答案 0 :(得分:1)
您不需要明确指定您发送的任何不合格邮件的接收者,因为它隐式self
。因此,在您的情况下,method(:get)
会告诉您发送给get
的{{1}}方法实现了谁/什么。