method
assert_not_deprecated
v7.2.3 -
Show latest stable
- Class:
ActiveSupport::Testing::Deprecation
assert_not_deprecated(deprecator, &block)public
Asserts that no deprecation warnings are emitted by the given deprecator during the execution of the yielded block.
assert_not_deprecated(CustomDeprecator) do CustomDeprecator.warn "message" # fails assertion end assert_not_deprecated(ActiveSupport::Deprecation.new) do CustomDeprecator.warn "message" # passes assertion, different deprecator end