How to test Ruby output and logs using RSpec with StringIO
06-Nov-2018 3104
Testing what is logged when you application is run can be done with testing method calls to your logger. However, using StringIO to capture and examine its output can provide several advantages, such as being able to record output and perform tests on it as a String.
How to test Ruby output and logs using RSpec with StringIO #ruby #rubydeveloper #rubyonrails #output #using #RSpec #StringIO #rspec #test https://rubyonrails.ba/link/how-to-test-ruby-output-and-logs-using-rspec-with-stringio