Class HighLine::Simulate
In: lib/highline/simulate.rb
Parent: Object

Simulates Highline input for use in tests.

Methods

eof?   getbyte   gets   new   with  

Public Class methods

Creates a simulator with an array of Strings as a script

A wrapper method that temporarily replaces the Highline instance in $terminal with an instance of this object for the duration of the block

Public Instance methods

The simulator handles its own EOF

Simulate StringIO#getbyte by shifting a single character off of the next line of the script

Simulate StringIO#gets by shifting a string off of the script

[Validate]