summaryrefslogtreecommitdiff
path: root/test/ruby
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-10-11 06:50:31 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-10-11 06:50:31 +0000
commit104d173752b240dd9a52a4edf2f3715f540e629a (patch)
tree26c9b14e41f86b5b268e78a8ee3363df04066a6b /test/ruby
parent88e326eddaf90dd628d4b2ef013301ecc231b9b7 (diff)
test_string.rb: missing test
* test/ruby/test_string.rb (test_each_codepoint): missing test. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37142 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby')
-rw-r--r--test/ruby/test_string.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/ruby/test_string.rb b/test/ruby/test_string.rb
index 823c5c7c6d..2beaef3504 100644
--- a/test/ruby/test_string.rb
+++ b/test/ruby/test_string.rb
@@ -633,6 +633,12 @@ class TestString < Test::Unit::TestCase
assert_equal(67, res[2])
end
+ def test_each_codepoint
+ res = []
+ S("ABC").codepoints.each {|x| res << x}
+ assert_equal([65, 66, 67], res)
+ end
+
def test_each_line
save = $/
$/ = "\n"