summaryrefslogtreecommitdiffstats
path: root/bootstraptest
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-12-23 01:36:54 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-12-23 01:36:54 +0000
commit0a14b40e1e6af72452bd0161da751d84806971a6 (patch)
tree094f155720bc82224c041c9cee86440d3a265f88 /bootstraptest
parent87604aac51fa1046d44158098dd6be5954ab0eba (diff)
downloadruby-0a14b40e1e6af72452bd0161da751d84806971a6.tar.gz
ruby-0a14b40e1e6af72452bd0161da751d84806971a6.tar.xz
ruby-0a14b40e1e6af72452bd0161da751d84806971a6.zip
add a test for [ruby-core:14288].
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@14508 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'bootstraptest')
-rw-r--r--bootstraptest/test_knownbug.rb10
1 files changed, 9 insertions, 1 deletions
diff --git a/bootstraptest/test_knownbug.rb b/bootstraptest/test_knownbug.rb
index 91e3cd5e4..74981190d 100644
--- a/bootstraptest/test_knownbug.rb
+++ b/bootstraptest/test_knownbug.rb
@@ -3,9 +3,17 @@
# So all tests will cause failure.
#
-assert_normal_exit %{
+assert_normal_exit %q{
def foo(&block)
yield if block
end
foo(&:bar)
}, '[ruby-core:14279]'
+
+assert_equal 'ok', %q{
+ open("tmp", "w") {|f| f.write "a\u00FFb" }
+ s = open("tmp", "r:iso-8859-1:utf-8") {|f|
+ f.gets("\xFF".force_encoding("iso-8859-1"))
+ }
+ s == "a\xFF" ? :ok : :ng
+}, '[ruby-core:14288]'