PageRenderTime 48ms CodeModel.GetById 24ms RepoModel.GetById 0ms app.codeStats 0ms

/vendor/gems/facets-2.4.5/test/core/string/test_methodize.rb

https://bitbucket.org/mediashelf/fedora-migrator
Ruby | 25 lines | 19 code | 6 blank | 0 comment | 0 complexity | e0ede5e443068ded2d4fec4d3c46a74f MD5 | raw file
Possible License(s): GPL-3.0, GPL-2.0, IPL-1.0, AGPL-1.0, LGPL-3.0
  1. require 'facets/string/methodize'
  2. require 'test/unit'
  3. class TC_String_Methodize < Test::Unit::TestCase
  4. def test_methodize_modulename
  5. a = "FooBase"
  6. r = "foo_base"
  7. assert_equal(r, a.methodize)
  8. end
  9. def test_methodize_pathname
  10. a = "foo/base"
  11. r = "foo__base"
  12. assert_equal(r, a.methodize)
  13. end
  14. def test_methodize_namespace
  15. a = "Foo::Base"
  16. r = "foo__base"
  17. assert_equal(r, a.methodize)
  18. end
  19. end