From ea1b9d58b995f9ced8a4e92c7e5b459569ec921f Mon Sep 17 00:00:00 2001 From: matz Date: Mon, 17 Dec 2007 09:08:27 +0000 Subject: * string.c (rb_str_index): check if substring is broken. * string.c (rb_str_rindex): ditto. * string.c (rb_str_succ): should carry over. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14268 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- bootstraptest/test_knownbug.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'bootstraptest') diff --git a/bootstraptest/test_knownbug.rb b/bootstraptest/test_knownbug.rb index 9426158496..b62fd1f6c8 100644 --- a/bootstraptest/test_knownbug.rb +++ b/bootstraptest/test_knownbug.rb @@ -219,12 +219,12 @@ assert_equal 'false', %q{ "\xa1\xa2\xa3\xa4".force_encoding("euc-jp").include?("\xa3".force_encoding("euc-jp")) } -assert_equal 'nil', %q{ - "\xa1\xa2\xa3\xa4".force_encoding("euc-jp").index("\xa3".force_encoding("euc-jp")) +assert_equal 'ok', %q{ + "\xa1\xa2\xa3\xa4".force_encoding("euc-jp").index("\xa3".force_encoding("euc-jp")) or :ok } -assert_equal 'nil', %q{ - "\xa1\xa2\xa3\xa4".force_encoding("euc-jp").rindex("\xa3".force_encoding("euc-jp")) +assert_equal 'ok', %q{ + "\xa1\xa2\xa3\xa4".force_encoding("euc-jp").rindex("\xa3".force_encoding("euc-jp")) or :ok } assert_equal 'false', %q{ -- cgit v1.2.3