From 6e21ec8d0f30b5495aa36aafaae15e93cb877bcd Mon Sep 17 00:00:00 2001 From: Tony Mack Date: Mon, 23 Jun 2008 17:21:55 +0000 Subject: [PATCH] added download_testscripts method (moved out of tests/node_run_tests) --- qaapi/qa/Nodes.py | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/qaapi/qa/Nodes.py b/qaapi/qa/Nodes.py index 097e497..ee0cf3a 100644 --- a/qaapi/qa/Nodes.py +++ b/qaapi/qa/Nodes.py @@ -124,7 +124,23 @@ class Node(dict, VRemote): time.sleep(30) return ready - + + def download_testscripts(self): + node_tests_dir = self['tests_dir'] + (archive_filename, archive_path) = self.config.archive_node_tests() + self.scp_to(archive_path, node_tests_dir) + + # Extract tests archive + tarx_cmd = "cd %(tests_dir)s && tar -xzm -f %(archive_filename)s" % locals() + print >> self.logfile, tarx_cmd + self.popen(tarx_cmd) + + # Make tests executable + # XX Should find a better way to do this + chmod_cmd = "cd %s/node && chmod -R 755 * " % (tests_dir ) + print >> self.logfile, chmod_cmd + self.popen(chmod_cmd) + class Nodes(Table): def __init__(self, config, nodes): -- 2.47.0