Skip to content

Commit

Permalink
drop STDIN.tty? hack
Browse files Browse the repository at this point in the history
this was necessary to get older version of highline up and running in rails
see #178 df5cffb
  • Loading branch information
kbrock committed Mar 21, 2023
1 parent 40c910f commit 21418cb
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,6 @@
SimpleCov.start
end

# In GitHub Actions (CI), we do not have a tty, so the various tests that use
# STDIN in order to test interactivity will fail. This code creates a psuedo-tty
# in that environment. If you want to test locally in a "non-tty" way, you can
# run the tests as follows: `true | bundle exec rake 2>&1 | cat`
unless STDIN.tty?
require "pty"
require "io/console"
_master_io, slave_file = PTY.open
slave_file.raw!
STDIN.reopen(slave_file)
end

require "manageiq-appliance_console"
ManageIQ::ApplianceConsole.logger = Logger.new("/dev/null")

Expand Down

0 comments on commit 21418cb

Please sign in to comment.