Does anybody know where I can get the expect.rb ? 

As defined, here in Japanese:
http://www.ruby-lang.org/ja/man/index.cgi?cmd=view;name=expect.rb

See the ab-lib translation below:

########################################################
#ab-lib Translated Japanese 
########################################################

The Expect Library is tlc's Expect package. In Ruby it is part of the IO class.

Example usage:
	IO#expect(pattern, timeout=99999)

With the expect method you can directly interact with inline text
interfaces. Expect uses string patterns and Regexp to read the input
from device. 

One example, of a piece of equipment where Expect could be
used might be a router with either ssh or telnet enabled. Expect can be
called in a Ruby program to process the inline text on the host device.

When an expected pattern is found, a response will be sent. If the
pattern does not appear, the timeout will expire and move to the next
statement. Practically, Expect has been used to reset passwords on routers. 
Expect has been used to run nightly updates on telephone switches.
Expect has been used to setup HP printers. Additionally, expect can be
used to modify any device with a inline text interface.

-- 
------------------------------------------
Ted Knab
Chester, MD 21619
------------------------------------------
35570707f6274702478656021626f6c6964796f6e602f66602478656
02e6164796f6e60237471647560216e6460276c6f62616c60257e696
4797e2a0