我无法从RubyMine调试rspec。我创建了一个调试配置,但是运行它时,我在规范的第一行出现了错误
require 'spec_helper'
Uncaught exception: cannot load such file -- spec_helper
。
我可以使用以下命令从命令行运行相同的规格,而不会出现错误:rspec /Users/me/git/myproject/spec/models/myspec_spec.rb
有什么主意,从RubyMine运行rspec
命令与命令行之间有什么不同,这可能导致此错误?
编辑:
完整的异常跟踪:
Uncaught exception: cannot load such file -- spec_helper
/Users/me/.rvm/rubies/ruby-2.5.1/lib/ruby/site_ruby/2.5.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/Users/me/.rvm/rubies/ruby-2.5.1/lib/ruby/site_ruby/2.5.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/Users/me/git/myapp/spec/models/myspec.rb:1:in `<top (required)>'
/Users/me/.rvm/gems/ruby-2.5.1@global/gems/ruby-debug-ide-0.7.0.beta6/bin/rdebug-ide:187:in `<main>'