Robot Framework Library¶
etr
provides the following Robot libraries that provides additional keywords when using the
robot plugin:
EtrUtils
EtrUtils
¶
Keywords¶
Get Random Port
Returns a random free port.
Example:
*** Settings ***
Library EtrUtils
*** Test Cases ***
Example Test
${port} = Get Random Port
Start Process myServer --port ${port}
Wait For Connection <host> <port> <timeout> [reason] [interval]
Wait for TCP connection to be accepted on host:port or give up specified time timeout. timout must be be in Robot Framework’s time format, e.g. 2 s, 1 min, 1 minute 2 seconds.
Example:
*** Settings ***
Library EtrUtils
*** Test Cases ***
Example
Wait For Connection localhost 80 6s Wait for web server
Wait For Path <pathname> <timeout> [reason] [interval]
Wait for path element (e.g. file or directory) to exist or give up specified time timeout. timout must be be in Robot Framework’s time format, e.g. 2 s, 1 min, 1 minute 2 seconds.
Example:
*** Settings ***
Library Process
Library EtrUtils
*** Test Cases ***
Example
Start Process <daemon writing daemon.pid>
Wait For Path daemon.pid 6s Wait for pidfile