PageRenderTime 47ms CodeModel.GetById 21ms RepoModel.GetById 1ms app.codeStats 0ms

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

https://bitbucket.org/mediashelf/fedora-migrator
Ruby | 18 lines | 14 code | 4 blank | 0 comment | 0 complexity | 282d25e14b80d46a141eaa3308ced310 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/chomp' # FIXME
  2. require 'test/unit'
  3. class Test_String < Test::Unit::TestCase
  4. def test_lchomp
  5. s = "xxboo"
  6. r = s.lchomp("xx")
  7. assert_equal( "boo", r )
  8. end
  9. def test_lchomp!
  10. s = "xxboo"
  11. s.lchomp!("xx")
  12. assert_equal( "boo", s )
  13. end
  14. end