diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2014-12-11 00:37:58 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2014-12-11 00:37:58 +0000 |
commit | 5c100b57f8c2f2513b0cf975d51b44b93a131070 (patch) | |
tree | 1a3983d6267824737760202f49b523aa19fd36ef /test | |
parent | 0eebb8f1c0833b4897cfe2e5eb578951e86f88dd (diff) | |
download | ruby-5c100b57f8c2f2513b0cf975d51b44b93a131070.tar.gz |
string.c: term fill
* string.c (rb_str_squeeze_bang): fill wchar terminator.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48768 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r-- | test/-ext-/string/test_cstr.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/test/-ext-/string/test_cstr.rb b/test/-ext-/string/test_cstr.rb index 86670dc6e2..9c2b73f695 100644 --- a/test/-ext-/string/test_cstr.rb +++ b/test/-ext-/string/test_cstr.rb @@ -68,6 +68,10 @@ class Test_StringCStr < Test::Unit::TestCase assert_wchars_term_char("foobar") {|s| s.delete!("ao".encode(s.encoding))} end + def test_wchar_squeeze! + assert_wchars_term_char("foo!") {|s| s.squeeze!} + end + def assert_wchars_term_char(str) result = {} WCHARS.map do |enc| |