aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/test
diff options
context:
space:
mode:
authorXavier Noria <fxn@hashref.com>2011-10-29 01:07:54 -0700
committerXavier Noria <fxn@hashref.com>2011-10-29 01:07:54 -0700
commit0fc531392d1f606054a6d6e394304c72a846d4c8 (patch)
treea272ee64d7012b0f182ac8e3b93e1cfb6a866973 /activesupport/test
parent2e74334abdf7df2b663cd96711693d710cffdccc (diff)
downloadrails-0fc531392d1f606054a6d6e394304c72a846d4c8.tar.gz
rails-0fc531392d1f606054a6d6e394304c72a846d4c8.tar.bz2
rails-0fc531392d1f606054a6d6e394304c72a846d4c8.zip
let demodulize do less work, and add tests
This is also faster on 1.9.
Diffstat (limited to 'activesupport/test')
-rw-r--r--activesupport/test/inflector_test.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/activesupport/test/inflector_test.rb b/activesupport/test/inflector_test.rb
index 5c956e0075..7d15b3c7e5 100644
--- a/activesupport/test/inflector_test.rb
+++ b/activesupport/test/inflector_test.rb
@@ -194,6 +194,8 @@ class InflectorTest < Test::Unit::TestCase
def test_demodulize
assert_equal "Account", ActiveSupport::Inflector.demodulize("MyApplication::Billing::Account")
+ assert_equal "Account", ActiveSupport::Inflector.demodulize("Account")
+ assert_equal "", ActiveSupport::Inflector.demodulize("")
end
def test_foreign_key