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

Unified Diff: components/cronet/tools/cr_cronet.py

Issue 601863002: Improve cr_cronet.py - pass unknown options to test runner and debugger (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Sync. Created 6 years, 3 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/cronet/tools/cr_cronet.py
diff --git a/components/cronet/tools/cr_cronet.py b/components/cronet/tools/cr_cronet.py
index 5aca9a6e3d4884dde02e3a3d8f17d89a56eac777..59a93511ca6bcac7d3d7f2c3d9da01c38bbc9d23 100755
--- a/components/cronet/tools/cr_cronet.py
+++ b/components/cronet/tools/cr_cronet.py
@@ -28,8 +28,9 @@ def main():
parser.add_argument('-r', '--release', action='store_true',
help='use release configuration')
- options = parser.parse_args()
+ options, unknown_options = parser.parse_known_args()
print options
+ print unknown_options
gyp_defines = 'GYP_DEFINES="OS=android enable_websockets=0 '+ \
'disable_file_support=1 disable_ftp_support=1 '+ \
'use_icu_alternatives_on_android=1" '
@@ -52,7 +53,14 @@ def main():
return run ('ninja -C ' + out_dir + ' cronet_sample_proguard_apk')
if (options.command=='test'):
return run ('build/android/test_runner.py instrumentation '+ \
- release_arg + ' --test-apk=CronetTestInstrumentation')
+ release_arg + ' --test-apk=CronetTestInstrumentation ' + \
+ ' '.join(unknown_options))
+ if (options.command=='debug'):
+ return run ('build/android/adb_gdb --start ' + \
+ '--activity=.CronetTestActivity ' + \
+ '--program-name=CronetTest ' + \
+ '--package-name=org.chromium.cronet_test_apk ' + \
+ ' '.join(unknown_options))
parser.print_help()
return 1
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698