]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
qa: fix vstart_runner tasks import
authorJohn Spray <john.spray@redhat.com>
Wed, 21 Dec 2016 12:23:14 +0000 (12:23 +0000)
committerJohn Spray <john.spray@redhat.com>
Thu, 5 Jan 2017 13:43:39 +0000 (13:43 +0000)
Instead of hunting around the filesystem for
ceph-qa-suite, get it from our own location.

Signed-off-by: John Spray <john.spray@redhat.com>
qa/tasks/vstart_runner.py

index 67da66a62d8a5504fe124a7148db3f75baba497f..629c89162b9b33fea085c991962438806f66ebb5 100644 (file)
@@ -86,12 +86,17 @@ if os.path.exists("./CMakeCache.txt") and os.path.exists("./bin"):
     # A list of candidate paths for each package we need
     guesses = [
         ["~/git/teuthology", "~/scm/teuthology", "~/teuthology"],
-        ["~/git/ceph-qa-suite", "~/scm/ceph-qa-suite", "~/ceph-qa-suite"],
         ["lib/cython_modules/lib.2"],
         ["../src/pybind"],
     ]
 
     python_paths = []
+
+    # Up one level so that "tasks.foo.bar" imports work
+    python_paths.append(os.path.abspath(
+        os.path.join(os.path.dirname(os.path.realpath(__file__)), "..")
+    ))
+
     for package_guesses in guesses:
         for g in package_guesses:
             g_exp = os.path.abspath(os.path.expanduser(g))