Hi,
I am using pxssh to create an ssh connection with a server. this pxssh is defined in a script called session.py. in session.py i create an ssh connection and then send commands to be executed in that session and after execution of commends it will exit the ssh connection.
Now i am calling this script using subprocess.call () ,from master script called testrunner.py.
this testrunner.py calls sessioon.py again and again for eac test case. so for each testcases ssh is created and commands are executed.
I want that ssh creation happens only for 1st test case (i.e. when session.py is called for first time) and for subsequent calls it uses the same session.
is it possible to do like this?
I am using pxssh to create an ssh connection with a server. this pxssh is defined in a script called session.py. in session.py i create an ssh connection and then send commands to be executed in that session and after execution of commends it will exit the ssh connection.
Now i am calling this script using subprocess.call () ,from master script called testrunner.py.
this testrunner.py calls sessioon.py again and again for eac test case. so for each testcases ssh is created and commands are executed.
I want that ssh creation happens only for 1st test case (i.e. when session.py is called for first time) and for subsequent calls it uses the same session.
is it possible to do like this?