1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* ext/io/console/console.c (console_dev): take care of no-ctty

case.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32065 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2011-06-13 14:28:53 +00:00
parent bcfc22b10e
commit a7b0b52f09
3 changed files with 32 additions and 8 deletions

View file

@ -160,3 +160,13 @@ class TestIO_Console < Test::Unit::TestCase
s.close if s
end
end if defined?(PTY) and defined?(IO::console)
class TestIO_Console < Test::Unit::TestCase
require_relative '../../ruby/envutil'
def test_noctty
assert_in_out_err(["-rio/console"],
"Process.daemon(true, true); p IO.console",
["nil"])
end
end if defined?(Process.daemon) and defined?(IO::console)