I'm currently writing specs for my Rails controller. I can't seem to get any puts statement or binding.pry, or binding.remote_pry working.
I am able to get the remote pry working in the development environment.
group :development, :test do
gem 'rspec-rails', '~> 3.0'
gem 'capybara'
gem 'factory_girl_rails'
gem 'daemons'
gem 'pry-rails'
gem 'pry-remote'
gem 'binding_of_caller'
end
It seems that you need to require 'pry'
somewhere in your test environment before invoking it. Your spec_helper.rb
, test_helper.rb
or similar is probably a good place.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With