]> code.ossystems Code Review - openembedded-core.git/commit
oeqa/utils: sshcontrol: rewrite the SSHControl class
authorStefan Stanacar <stefanx.stanacar@intel.com>
Tue, 28 Jan 2014 13:55:32 +0000 (15:55 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Sun, 2 Feb 2014 11:21:54 +0000 (11:21 +0000)
commitbb14a7598d3c0636dc249f719bde0d9d65b2694d
treea9049653fec8f982b9738c64b9b9f82d89368982
parent34bd53c657f82a402723fcf2640b0511a68b6af5
oeqa/utils: sshcontrol: rewrite the SSHControl class

Split the class in two, one to handle the process and the
timeout based on output and one for the actual ssh/scp commands.
The ssh/scp methods now use the same run method.
It does the same thing as before but:
- it looks cleaner.
- adds support for using a different user than root
- optionally, raises an exception when exit code != 0
(that's useful for code outside of tests, where you wouldn't want
to check the return code every time as the tests do)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
meta/lib/oeqa/utils/sshcontrol.py