Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(285)

Unified Diff: build/android/pylib/instrumentation/test_runner.py

Issue 1571803002: [Android] Prepare build/android/ for catapult+devil. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@create-device-library-links
Patch Set: rebase Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « build/android/pylib/instrumentation/test_jar.py ('k') | build/android/pylib/linker/setup.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/android/pylib/instrumentation/test_runner.py
diff --git a/build/android/pylib/instrumentation/test_runner.py b/build/android/pylib/instrumentation/test_runner.py
index aab0c12448105e250682debc66fd9dee17d26860..003a74c76e929e0dad2fbf384433620124f62bd2 100644
--- a/build/android/pylib/instrumentation/test_runner.py
+++ b/build/android/pylib/instrumentation/test_runner.py
@@ -8,7 +8,6 @@ import collections
import logging
import os
import re
-import sys
import time
from devil.android import device_errors
@@ -17,14 +16,14 @@ from pylib import flag_changer
from pylib import valgrind_tools
from pylib.base import base_test_result
from pylib.base import base_test_runner
+from pylib.constants import host_paths
from pylib.instrumentation import instrumentation_test_instance
from pylib.instrumentation import json_perf_parser
from pylib.instrumentation import test_result
from pylib.local.device import local_device_instrumentation_test_run
-sys.path.append(os.path.join(constants.DIR_SOURCE_ROOT, 'build', 'util', 'lib',
- 'common'))
-import perf_tests_results_helper # pylint: disable=F0401
+with host_paths.SysPath(host_paths.BUILD_COMMON_PATH):
+ import perf_tests_results_helper # pylint: disable=import-error
_PERF_TEST_ANNOTATION = 'PerfTest'
@@ -109,7 +108,7 @@ class TestRunner(base_test_runner.BaseTestRunner):
# because it may have race condition when multiple processes are trying to
# launch lighttpd with same port at same time.
self.LaunchTestHttpServer(
- os.path.join(constants.DIR_SOURCE_ROOT), self._lighttp_port)
+ os.path.join(host_paths.DIR_SOURCE_ROOT), self._lighttp_port)
if self.flags:
flags_to_add = ['--disable-fre', '--enable-test-intents']
if self.options.device_flags:
« no previous file with comments | « build/android/pylib/instrumentation/test_jar.py ('k') | build/android/pylib/linker/setup.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698