Created
September 6, 2013 18:23
-
-
Save benhamill/6467858 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
gem 'activesupport', '4.0.0' | |
require 'minitest/autorun' | |
require 'active_support/inflector' | |
class BugTest < MiniTest::Unit::TestCase | |
def test_underscore_knows_about_acronyms_in_directories | |
ActiveSupport::Inflector.inflections(:en) do |inflect| | |
inflect.acronym 'OAuth' | |
end | |
assert_equal "oauth_thing", "OAuthThing".underscore # passes | |
assert_equal "foo/oauth_thing", "Foo::OAuthThing".underscore # fails | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment