Пример #1
0
 def remote_exec_file(self, script, test_name, result_query, test_detail, log_file):
     host = Execute.db_get("host", "localhost", 6379, 0)
     port = Execute.db_get("port", "localhost", 6379, 0)
     user = Execute.db_get("user", "localhost", 6379, 0)
     password = Execute.db_get("password", "localhost", 6379, 0)
     stdout = Execute.remote_exec_file(script, host=host, port=int(port), user=user, password=password, test_name=test_name, result_query=result_query, test_detail=test_detail, log_file=log_file)
     data = "{0}".format(stdout)
     d = data.replace('\\n', " ")
     return d
Пример #2
0
 def remote_key_exec(self, key, test_name, result_query, test_detail, log_file):
     dbhost  = "127.0.0.1"
     dbport = 6379
     dbnum = 0
     host = Execute.db_get("host", dbhost, dbport, dbnum)
     port = Execute.db_get("port", dbhost, dbport, dbnum)
     user = Execute.db_get("user", dbhost, dbport, dbnum)
     password = Execute.db_get("password", dbhost, dbport, dbnum)
     stdout = Execute.remote_exec_key(key, host=host, port=int(port), user=user, password=password, test_name=test_name, result_query=result_query, test_detail=test_detail, log_file=log_file, db_host=dbhost, db_port=dbport, db=dbnum)
     print stdout
     data = "{0}".format(stdout)
     d = data.replace('\\n', " ")
     return d