I have a quick question about breakpoints. I am testing a class method
inside a model in development mode and when I get to the breakpoint, I
can’t seem to inspect any of the local variables inside the method.
Here is what the code looks like:
@user = User.new(params[:user])
user = User.new(params[:user])
# do stuff
# do other stuff
I can inspect the instance variable just fine, but
if I try to inspect the ‘user’ local variable or params or options I
get the following exception:
ameError: undefined local variable or method
user' for User:Class from (druby://localhost:42531) /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.14.4/lib/active_record/base.rb:1129:inmethod_missing’
from (druby://localhost:42531) (irb):1:in `breakpoint’
I noticed the same thing happens in unit tests as well. Any ideas?
I am using rails 1.1.6 and ruby 1.8.5