forked from chromium/chromium
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Generating wrapper script for non-telemetry test migration to new rec…
…ipe. Refactored our execution of non-telemetry tests so we wouldn't have to generate new isolates for every non-telemetry test during migration. Instead you need to just pass --migrated-test=true in the src side json. Also pulled out the perf script deps so we wouldn't have to update every time the perf isolated script deps changed. Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.linux:linux_vr;master.tryserver.chromium.win:win_optional_gpu_tests_rel Change-Id: I27fac5c9a36f9321be80f0c60ab8b53eaefdc1c4 Reviewed-on: https://chromium-review.googlesource.com/995576 Reviewed-by: Ned Nguyen <nednguyen@google.com> Reviewed-by: Dirk Pranke <dpranke@chromium.org> Reviewed-by: Michael Wasserman <msw@chromium.org> Commit-Queue: Emily Hanley <eyaich@chromium.org> Cr-Commit-Position: refs/heads/master@{#548472}
- Loading branch information
Emily Hanley
authored and
Commit Bot
committed
Apr 5, 2018
1 parent
77dddb8
commit 39a0031
Showing
7 changed files
with
153 additions
and
113 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
#!/usr/bin/env python | ||
# Copyright 2018 The Chromium Authors. All rights reserved. | ||
# Use of this source code is governed by a BSD-style license that can be | ||
# found in the LICENSE file. | ||
|
||
"""This script is a wrapper script used during migration of performance | ||
tests to use the new recipe. See crbug.com/757933 | ||
Non-telemetry tests now will all run with this script. The flag | ||
--migrated-test will indicate if this test is using the new recipe or not. | ||
By default this script runs the legacy testing/scripts/run_gtest_perf_test.py. | ||
""" | ||
|
||
import argparse | ||
import os | ||
import subprocess | ||
import sys | ||
|
||
SRC_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath( | ||
__file__)))) | ||
|
||
GTEST = os.path.join(SRC_DIR, 'testing', 'scripts', 'run_gtest_perf_test.py') | ||
PERF = os.path.join(SRC_DIR, 'testing', 'scripts', 'run_performance_tests.py') | ||
|
||
|
||
def main(): | ||
parser = argparse.ArgumentParser() | ||
parser.add_argument('--migrated-test', type=bool, default=False) | ||
|
||
args, rest_args = parser.parse_known_args() | ||
|
||
if args.migrated_test: | ||
return subprocess.call([sys.executable, PERF] + rest_args) | ||
else: | ||
return subprocess.call([sys.executable, GTEST] + rest_args) | ||
|
||
|
||
if __name__ == '__main__': | ||
sys.exit(main()) |
Oops, something went wrong.