[rspec-users] rdebug spec ?

Luis Lavena luislavena at gmail.com
Tue Jun 12 02:37:08 EDT 2007

On 6/12/07, Jonathan Linowes <jonathan at parkerhill.com> wrote:
> Can you run rdebug on specs?
> I get errors when I try:
> $ rdebug spec ./spec/models/select_option_spec.rb
> ./spec: Is a directory - ./spec (Errno::EISDIR)
>         from /opt/local/lib/ruby/gems/1.8/gems/ruby-debug-0.9.3/bin/
> rdebug:136:in `debug_load'
>         from /opt/local/lib/ruby/gems/1.8/gems/ruby-debug-0.9.3/bin/
> rdebug:136
>         from /opt/local/bin/rdebug:16:in `load'
>         from /opt/local/bin/rdebug:16

Try the following:

require 'ruby-debug' at top of your spec file.

then, put 'debugger' inside your example block.

That worked for me, also in combination with spec -e (just to run a
specific example to pinpoint the problem).


Luis Lavena
Multimedia systems
Leaders are made, they are not born. They are made by hard effort,
which is the price which all of us must pay to achieve any goal that
is worthwhile.
Vince Lombardi

More information about the rspec-users mailing list