Script Syntax
You create a script using keywords. In general
the Script Syntax is Command=String
.
Command is either Send
, Expect
, SimpleExpect
, or Flow
Control
.
: A
script can have as many send and receive lines as needed. However,
the more you have, the slower the service checking.
Keywords
- To send a string to a port, use the Send= keyword.
- To expect a string from a port, use the
SimpleExpect= or the Expect= keyword.
- To comment out a line, use the # symbol as
the first character of the line.
- To have conditional responses on "error" or
"success" of a step within the scripts, use Flow Control Keywords.
Examples
If you have a TCP service to check where you
needed to do the following:
- expect something on connection
- send a command
- check for a response
- send something to disconnect