diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-06-11 09:02:11 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-06-11 09:02:11 +0000 |
commit | 34b19050b3894d3e6e072f68c112711696dc1c41 (patch) | |
tree | adcb58cdd3da4276818e43c5ba316855e2ebc46f /test/ruby/test_io_m17n.rb | |
parent | 6f58118e4c6b688aa8c78b5310c4e2c12c444537 (diff) | |
download | ruby-34b19050b3894d3e6e072f68c112711696dc1c41.tar.gz |
* io.c (io_getc): should be 7bit if ascii. fixes #4557
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32000 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby/test_io_m17n.rb')
-rw-r--r-- | test/ruby/test_io_m17n.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/ruby/test_io_m17n.rb b/test/ruby/test_io_m17n.rb index 86d45a50ae..091b04a5af 100644 --- a/test/ruby/test_io_m17n.rb +++ b/test/ruby/test_io_m17n.rb @@ -2060,5 +2060,14 @@ EOT r.close end) end + + def test_getc_ascii_only + bug4557 = '[ruby-core:35630]' + c = with_tmpdir { + open("a", "wb") {|f| f.puts "a"} + open("a", "rt") {|f| f.getc} + } + assert(c.ascii_only?, "should be ascii_only #{bug4557}") + end end |