AIB Test.xlsx (11.4 KB)
Hi Friends,
I have to run unix commands in Putty.But commands and responses are having wildcards & Dynamic Variables.
we have to use regular expressions only to match commands and compare the pattern of the response.
Replace the wildcard values
% is replaced with \s
- is replaced with .*
. is replaced with .
Example:
For this Command in the attached Test datasheet
echo Command run on $Server.
The Response
Command%run*$Server.
Is converted to this regular expression following the steps above.
^Command\srun.*RONA.$
And will match the output of the echo command
Command run on RONA.
Note: Attached the spreadsheet which contains two sheets.1)Instances 2)Commands
Value of dynamic variables in Command sheet are mentioned in Instances Sheet.
Dynamic variables are preceded by $ symbol.
Thanks,
Chandini.