On Sunday, July 16, 2017 at 6:17:56 PM UTC+1, Ralph Shnelvar wrote:
I suspect I have a name collision with *Class: > RSpec::Matchers::BuiltIn::Output* > <http://rspec.info/documentation/3.4/rspec-expectations/RSpec/Matchers/BuiltIn/Output.html> > but > I'm damned if I can figure out why. > > I guess I could leave the code as-is but ... advice would be appreciated. > You are correct. rspec added the ability to test that some code has written something to stdout. You use it like this: expect { print('foo') }.to output('foo').to_stdout To make this work, rspec defines an output method (that returns an Output matcher, which is the class that you see) which is the thing colliding with your method Fred -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/ae5bf767-a67d-46b4-9e56-66f5f81a03b8%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.

