Method capture

Can you check to see if minitest's `capture_io` will solve the problem?

If not, can you write a small example (outside rails) to demonstrate the
problem? This sounds like something we might want to push up to
minitest if possible.

Thanks Aaron for reply I write a gist for these cases, here you are

The new method, captures all descriptors, but I’m not sure about replacement original method.


I commented in your gist to use the StringIO instead of Tempfile to avoid IO on disk.

Thank you, let’s discuss it in PR

I think it will be more comfortable for us.