]> git-server-git.apps.pok.os.sepia.ceph.com Git - teuthology.git/commitdiff
Use suite_path, if set, for one-off jobs as well
authorZack Cerza <zack.cerza@inktank.com>
Tue, 19 Aug 2014 17:54:13 +0000 (11:54 -0600)
committerZack Cerza <zack.cerza@inktank.com>
Tue, 19 Aug 2014 17:54:13 +0000 (11:54 -0600)
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
teuthology/run.py

index 59e4d7f46b2459f4e08152563309f6a6b1b34646..96cca618c33c1352ff34bde0e57241bfb1640c41 100644 (file)
@@ -76,15 +76,16 @@ def fetch_tasks_if_needed(job_config):
     # in its config.
     suite_path = job_config.get('suite_path')
     if suite_path:
-        log.info("suite_path is set to %s; not fetching tasks", suite_path)
-        return
+        log.info("suite_path is set to %s; will attempt to use it", suite_path)
+        if suite_path not in sys.path:
+            sys.path.insert(1, suite_path)
 
     try:
         import tasks
         log.info("Found tasks at %s", os.path.dirname(tasks.__file__))
         return
     except ImportError:
-        pass
+        log.info("Tasks not found; will attempt to fetch")
 
     ceph_branch = job_config.get('branch', 'master')
     suite_branch = job_config.get('suite_branch', ceph_branch)