diff --git a/spec/support/deprecation.rb b/spec/support/deprecation.rb index a795aaae6..878af0d76 100644 --- a/spec/support/deprecation.rb +++ b/spec/support/deprecation.rb @@ -1,6 +1,7 @@ def with_deprecation_silenced(&block) + previous_value = ::ActiveSupport::Deprecation.silenced ::ActiveSupport::Deprecation.silenced = true yield - ::ActiveSupport::Deprecation.silenced = false + ::ActiveSupport::Deprecation.silenced = previous_value end