summaryrefslogtreecommitdiffstats
path: root/doctor_tests/common
diff options
context:
space:
mode:
authordongwenjuan <dong.wenjuan@zte.com.cn>2017-10-09 15:25:33 +0800
committerCarlos Goncalves <mail@cgoncalves.pt>2017-10-09 10:49:59 +0000
commit2c9569e66c4f0e333d603f93b280768bea4f2d07 (patch)
tree6459b8f961a8245fd1aaef8ba870fddf45706b1a /doctor_tests/common
parent5733b9ce1dcfb40e0ef6a956c0e6c092829fc6d6 (diff)
fix to get logfile
Change-Id: I44cc6c5108eb48191ca36cbcb44f787ea542f3ce Signed-off-by: dongwenjuan <dong.wenjuan@zte.com.cn> (cherry picked from commit b3dcaa337fa91b3123fa08e8b8dd2e81184a91dd)
Diffstat (limited to 'doctor_tests/common')
-rw-r--r--doctor_tests/common/utils.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/doctor_tests/common/utils.py b/doctor_tests/common/utils.py
index 2e823acb..d2962a8a 100644
--- a/doctor_tests/common/utils.py
+++ b/doctor_tests/common/utils.py
@@ -47,6 +47,11 @@ def match_rep_in_file(regex, full_path):
return None
+def get_doctor_test_root_dir():
+ current_dir = os.path.split(os.path.realpath(__file__))[0]
+ return os.path.dirname(current_dir)
+
+
class SSHClient(object):
def __init__(self, ip, username, password=None, pkey=None,
key_filename=None, log=None, look_for_keys=False,