зеркало из https://github.com/AvaloniaUI/angle.git
Fix import paths for //scripts/run_gtest_angle_test.py.
We added run_gtest_angle_test.py in a86c854
, but didn't
actually check that it worked :(. This CL adds the
missing sys.path imports needed to find the rest of
the Chromium test script modules.
Bug: chromium:816629, angleproject:3162
Change-Id: I4c381bda334df4d2e648aab65ca4cc0310d840bf
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2283694
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Dirk Pranke <dpranke@google.com>
This commit is contained in:
Родитель
69fa4d237a
Коммит
ba584cf7d8
|
@ -21,8 +21,6 @@ of tests. This list is parsed by this harness and sent down via the
|
|||
This script is intended to be the base command invoked by the isolate,
|
||||
followed by a subsequent non-python executable. For a similar script see
|
||||
run_performance_test.py.
|
||||
|
||||
# TODO(jmadill): Move this into the ANGLE repo. http://anglebug.com/3162
|
||||
"""
|
||||
|
||||
import argparse
|
||||
|
@ -33,16 +31,21 @@ import sys
|
|||
import tempfile
|
||||
import traceback
|
||||
|
||||
import common
|
||||
# Add //src/testing into sys.path for importing xvfb and test_env, and
|
||||
# //src/testing/scripts for importing common.
|
||||
d = os.path.dirname
|
||||
THIS_DIR = d(os.path.abspath(__file__))
|
||||
CHROMIUM_SRC_DIR = d(d(d(THIS_DIR)))
|
||||
sys.path.insert(0, os.path.join(CHROMIUM_SRC_DIR, 'testing'))
|
||||
sys.path.insert(0, os.path.join(CHROMIUM_SRC_DIR, 'testing', 'scripts'))
|
||||
|
||||
# Add src/testing/ into sys.path for importing xvfb and test_env.
|
||||
sys.path.append(os.path.join(os.path.dirname(__file__), '..'))
|
||||
import common
|
||||
import xvfb
|
||||
import test_env
|
||||
|
||||
# Unfortunately we need to copy these variables from ../test_env.py.
|
||||
# Importing it and using its get_sandbox_env breaks test runs on Linux
|
||||
# (it seems to unset DISPLAY).
|
||||
# Unfortunately we need to copy these variables from
|
||||
# //src/testing/scripts/test_env.py. Importing it and using its
|
||||
# get_sandbox_env breaks test runs on Linux (it seems to unset DISPLAY).
|
||||
CHROME_SANDBOX_ENV = 'CHROME_DEVEL_SANDBOX'
|
||||
CHROME_SANDBOX_PATH = '/opt/chromium/chrome_sandbox'
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче