RSpec won't stop at breakpoint (still)
Reported in March http://devnet.jetbrains.net/message/5298647#5298647
I've been debugging via terminal, but was hopeful that 3.2.4 would resolve this. I can run rspec tests from RM just fine. When I debug, it fails with
/Users/digger69/.rvm/rubies/ruby-1.9.2-p290/bin/ruby -e at_exit{sleep(1)};$stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift) /Users/digger69/.rvm/gems/ruby-1.9.2-p290@myrvm/gems/ruby-debug-ide-0.4.17.beta8/bin/rdebug-ide --port 51421 -- /Users/digger69/.rvm/gems/ruby-1.9.2-p290@myrvm/bin/rspec /Users/digger69/RubymineProjects/myrvmgit/spec/controllers/tasks_controller_spec.rb --require teamcity/spec/runner/formatter/teamcity/formatter --format Spec::Runner::Formatter::TeamcityFormatter --example TasksController\ when\ authenticated\ listing\ tasks\ should\ assign\ tasks\ I\ have\ access\ to
Testing started at 9:53 AM ...
Fast Debugger (ruby-debug-ide 0.4.17.beta8, ruby-debug-base 0.11.30.pre2) listens on 127.0.0.1:51421
/Users/digger69/.rvm/gems/ruby-1.9.2-p290@myrvm/gems/ruby-debug-base19-0.11.24/lib/ruby_debug.bundle: warning: already initialized constant VERSION
`include Capybara` is deprecated please use `include Capybara::DSL` instead.
`include Capybara` is deprecated please use `include Capybara::DSL` instead.
`include Capybara` is deprecated please use `include Capybara::DSL` instead.
Empty test suite.
Empty test suite.
Empty test suite.
Empty test suite.
Empty test suite.
Empty test suite.
Empty test suite.
Empty test suite.
RuntimeError: Debugger.start is not called yet.
/Users/digger69/.rvm/gems/ruby-1.9.2-p290@myrvm/gems/ruby-debug19-0.11.6/cli/ruby-debug/processor.rb:130:in `breakpoints'
/Users/digger69/.rvm/gems/ruby-1.9.2-p290@myrvm/gems/ruby-debug19-0.11.6/cli/ruby-debug/processor.rb:130:in `at_breakpoint'
(eval):5:in `block in at_breakpoint'
<internal:prelude>:10:in `synchronize'
(eval):3:in `at_breakpoint'
Using rails 3.0.10 and ruby 1.9.2p290 on OSx 10.6.8
请先登录再写评论。
Please update ruby-debug-base19x to the latest pre version using gem update ruby-debug-base19x --pre
Thanks for the reply Dennis. I believe RM asked me to do that when it first ran, but I tried again from terminal and it confirmed already up to date:
$ gem update ruby-debug-base19x --pre
Updating installed gems
Nothing to update
Mark
I have the same problem as the OP. I also verified thatmy ruby-debug-base19x gem is up-to-date. Breakpoints in rspec tests are simply ignored.
gem update ruby-debug-base19x --pre
Updating installed gems
Nothing to update
bump
A good friend found identified the issue .. my spec_helper.rb had:
require 'ruby-debug'
commenting that out resolved the problem.
This is in spec_helper since we have some devs using other IDEs, debugging from terminal.
Hope this helps others.
Incase it helps anyone I had the same issue. Be sure that you don't have something like `gem 'debugger'` hanging out in your Gemfile either. This will try to require it by default and cause issues.
If you need to support both ruby and rubymine debugging, make sure to specify `require: false` for the debugger in your Gemfile then put `require 'debugger' unless ENV['RM_INFO']` in your spec_helper.rb