提交 90520d2e 编写于 作者: A Andrew White

Remove deprecated method Numeric#to_formatted_s

上级 7c848e6d
* Remove deprecated method `Numeric#to_formatted_s`
*Andrew White*
* Remove deprecated method `alias_method_chain`
*Andrew White*
......
......@@ -126,11 +126,6 @@ def to_s(*args)
end
end
end
def to_formatted_s(*args)
to_s(*args)
end
deprecate to_formatted_s: :to_s
end
# Ruby 2.4+ unifies Fixnum & Bignum into Integer.
......
......@@ -376,12 +376,6 @@ def test_to_s__injected_on_proper_types
assert_equal "1 Million", BigDecimal("1000010").to_s(:human)
end
def test_to_formatted_s_is_deprecated
assert_deprecated do
5551234.to_formatted_s(:phone)
end
end
def test_to_s_with_invalid_formatter
assert_equal "123", 123.to_s(:invalid)
assert_equal "2.5", 2.5.to_s(:invalid)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册