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

Unified Diff: build/android/pylib/gtest/gtest_test_instance.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
Index: build/android/pylib/gtest/gtest_test_instance.py
diff --git a/build/android/pylib/gtest/gtest_test_instance.py b/build/android/pylib/gtest/gtest_test_instance.py
index 4250ea3ddd4eeb7ffd0f37647eb9399a4e07ffcb..a118ea76ceb36f7bbaac3a0d6b87437e7ebf9402 100644
--- a/build/android/pylib/gtest/gtest_test_instance.py
+++ b/build/android/pylib/gtest/gtest_test_instance.py
@@ -5,17 +5,16 @@
import logging
import os
import re
-import sys
import tempfile
from devil.android import apk_helper
from pylib import constants
+from pylib.constants import host_paths
from pylib.base import base_test_result
from pylib.base import test_instance
-sys.path.append(os.path.join(
- constants.DIR_SOURCE_ROOT, 'build', 'util', 'lib', 'common'))
-import unittest_util # pylint: disable=import-error
+with host_paths.SysPath(host_paths.BUILD_COMMON_PATH):
+ import unittest_util # pylint: disable=import-error
BROWSER_TEST_SUITES = [
@@ -176,7 +175,7 @@ class GtestTestInstance(test_instance.TestInstance):
default_isolate_file_path = _DEFAULT_ISOLATE_FILE_PATHS.get(self._suite)
if default_isolate_file_path:
args.isolate_file_path = os.path.join(
- constants.DIR_SOURCE_ROOT, default_isolate_file_path)
+ host_paths.DIR_SOURCE_ROOT, default_isolate_file_path)
if args.isolate_file_path:
self._isolate_abs_path = os.path.abspath(args.isolate_file_path)
@@ -315,7 +314,7 @@ class GtestTestInstance(test_instance.TestInstance):
disabled_filter_items += ['*.%s*' % dp for dp in disabled_prefixes]
disabled_tests_file_path = os.path.join(
- constants.DIR_SOURCE_ROOT, 'build', 'android', 'pylib', 'gtest',
+ host_paths.DIR_SOURCE_ROOT, 'build', 'android', 'pylib', 'gtest',
'filter', '%s_disabled' % self._suite)
if disabled_tests_file_path and os.path.exists(disabled_tests_file_path):
with open(disabled_tests_file_path) as disabled_tests_file:
« no previous file with comments | « build/android/pylib/constants/host_paths.py ('k') | build/android/pylib/host_driven/test_info_collection.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698