module RuboCop::Util
This module contains a collection of useful utility methods.
Public Class Methods
silence_warnings() { || ... }
click to toggle source
# File lib/rubocop/util.rb, line 6 def self.silence_warnings # Replaces Kernel::silence_warnings since it hides any warnings, # including the RuboCop ones old_verbose = $VERBOSE $VERBOSE = nil yield ensure $VERBOSE = old_verbose end