Fix path construction in perf runner.
authormachenbach <machenbach@chromium.org>
Thu, 4 Dec 2014 08:58:01 +0000 (00:58 -0800)
committerCommit bot <commit-bot@chromium.org>
Thu, 4 Dec 2014 08:58:09 +0000 (08:58 +0000)
BUG=chromium:374740
LOG=n
TEST=python -m unittest run_perf_test
TBR=ulan@chromium.org
NOTRY=true

Review URL: https://codereview.chromium.org/776873005

Cr-Commit-Position: refs/heads/master@{#25651}

tools/run_perf.py

index 02cfe63beda435b3966b4dcca914d6e607c73c22..0a24c08e0775ad75057e3bfc9049c9ad97d7cd16 100755 (executable)
@@ -534,8 +534,11 @@ class AndroidPlatform(Platform):  # pragma: no cover
 
   def PreTests(self, node, path):
     suite_dir = os.path.abspath(os.path.dirname(path))
-    bench_dir = os.path.join(suite_dir,
-                             os.path.normpath(os.path.join(*node.path)))
+    if node.path:
+      bench_dir = os.path.join(suite_dir,
+                               os.path.normpath(os.path.join(*node.path)))
+    else:
+      bench_dir = suite_dir
 
     self._PushFile(self.shell_dir, node.binary)
     if isinstance(node, Runnable):