The original version of this logic (0a0f49e9) looked for src dirs in
site-tests when every reference I have found uses site_tests (w/ an
underscore).

Additionally it seems the current default location for site_tests is
base_autotest + "/tmp/site_tests" as per what I found when triaging
the current client/tests/iosched_bugs make failure so add a "tmp" based
version to the search path as well.

Signed-off-by: Daniel DeFolo <[email protected]>
---
 client/shared/base_utils.py |   10 ++++++++--
 1 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/client/shared/base_utils.py b/client/shared/base_utils.py
index d0f6ad6..6dbe4de 100644
--- a/client/shared/base_utils.py
+++ b/client/shared/base_utils.py
@@ -770,12 +770,18 @@ def update_version(srcdir, preserve_srcdir, new_version, 
install,
         module_name = os.path.basename(os.path.dirname(srcdir))
         module_parent = os.path.dirname(srcdir)
         base_autotest = os.path.abspath(os.path.join(module_parent, "..", 
".."))
+        tmp_autotest = os.path.join(base_autotest, 'tmp')
         tests_dir = os.path.join(base_autotest, 'tests')
-        site_tests_dir = os.path.join(base_autotest, 'site-tests')
+        site_tests_dir = os.path.join(base_autotest, 'site_tests')
+        tmp_site_tests_dir = os.path.join(tmp_autotest, 'site_tests')
         profilers_dir = os.path.join(base_autotest, 'profilers')
         other_tests_dir = settings.get_value("COMMON", "test_dir", default="")
         source_code_dir = ""
-        for d in [other_tests_dir, site_tests_dir, tests_dir, profilers_dir]:
+        for d in [other_tests_dir,
+                  tmp_site_tests_dir,
+                  site_tests_dir,
+                  tests_dir,
+                  profilers_dir]:
             source_code_dir = os.path.join(d, module_name, "src")
             if os.path.isdir(source_code_dir):
                 break
-- 
1.7.7.6

_______________________________________________
Autotest-kernel mailing list
[email protected]
https://www.redhat.com/mailman/listinfo/autotest-kernel

Reply via email to