in reply to Perl's Telnet vs. Expect Module
Expect supports your decision making much more smoothly than telnet.
From a purpose point of view, telnet is not made to matching output for you, although Perl's telnet module does cover this a little bit, for example waitfor(), but very basic. From the perception of the author of telnet module, that is not what he should focus on, and spent time on. So even in the future, you don't expect the module to extend on this.
Expect is made for the purpose of making decisions base on output.
Also it makes sense to unplug the underneath communication stuff from your decision making process. Expect does not require telnet, in fact the output can come from any program. In case the source of your output is changed (the data under analysis is now coming from a different source), the majority of your script would still be useful, if it is based on Expect.
|
|---|