You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
defsilence_output# Store the original stderr and stdout in order to restore them later@original_stderr= $stderr
@original_stdout= $stdout
# Redirect stderr and stdout
$stderr =File.new("out.txt",'w')
$stdout =File.new("out.txt",'w')end# Replace stderr and stdout so anything else is output correctlydefenable_output
$stderr =@original_stderr
$stdout =@original_stdout@original_stderr=nil@original_stdout=nilenddefteardownenable_outputenddefsetupsilence_outputend
It would be nice to have an option that does the same thing without having to add those methods.
The text was updated successfully, but these errors were encountered:
Im using this quite a lot:
It would be nice to have an option that does the same thing without having to add those methods.
The text was updated successfully, but these errors were encountered: