Skip to content
Permalink
Browse files
Remove deprecated #acronym_regex method from Inflections
  • Loading branch information
rafaelfranca committed Jan 17, 2019
1 parent 6c745b0 commit 0ce67d3cd6d1b7b9576b07fecae3dd5b422a5689
@@ -763,7 +763,6 @@ class RequestMethod < BaseRequestTest

test "post uneffected by local inflections" do
existing_acronyms = ActiveSupport::Inflector.inflections.acronyms.dup
assert_deprecated { ActiveSupport::Inflector.inflections.acronym_regex.dup }
begin
ActiveSupport::Inflector.inflections do |inflect|
inflect.acronym "POS"
@@ -1,3 +1,7 @@
* Remove deprecated `#acronym_regex` method from `Inflections`.

*Rafael Mendonça França*

* Fix `String#safe_constantize` throwing a `LoadError` for incorrectly cased constant references.

*Keenan Brock*
@@ -65,8 +65,7 @@ def self.instance(locale = :en)
@__instance__[locale] ||= new
end

attr_reader :plurals, :singulars, :uncountables, :humans, :acronyms, :acronym_regex
deprecate :acronym_regex
attr_reader :plurals, :singulars, :uncountables, :humans, :acronyms

attr_reader :acronyms_camelize_regex, :acronyms_underscore_regex # :nodoc:

@@ -224,12 +224,6 @@ def test_underscore_acronym_sequence
assert_equal("json_html_api", ActiveSupport::Inflector.underscore("JSONHTMLAPI"))
end

def test_acronym_regexp_is_deprecated
assert_deprecated do
ActiveSupport::Inflector.inflections.acronym_regex
end
end

def test_underscore
CamelToUnderscore.each do |camel, underscore|
assert_equal(underscore, ActiveSupport::Inflector.underscore(camel))

0 comments on commit 0ce67d3

Please sign in to comment.