在rspec中使用ruby-debug(通过rspec -d),调试器在执行“next”时拒绝跳过语句
似乎总是进入声明
debugger
params[:appointment][:user_id] =
User.where(email: appointment_params[:user_id]).pluck(:id).first if appointment_params[:user_id].to_i == 0
params[:appointment][:country_id] =
Country.where(name: appointment_params[:country_id]).pluck(:id).first if appointment_params[:country_id].to_i == 0
@appointment = Appointment.new(appointment_params)
当我点击“n”并按回车键时,它会进入User.where语句
我不知道是什么原因引起了这个想法?