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

Side by Side Diff: scripts/slave/recipe_modules/chromium_android/api.py

Issue 1869193003: Remove logcats from instrumentation test run steps. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/build
Patch Set: Rebase! Created 4 years, 8 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | scripts/slave/recipe_modules/chromium_android/example.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 2013 The Chromium Authors. All rights reserved. 1 # Copyright 2013 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 import contextlib 5 import contextlib
6 import datetime 6 import datetime
7 import json 7 import json
8 import os 8 import os
9 import re 9 import re
10 import urllib 10 import urllib
(...skipping 661 matching lines...) Expand 10 before | Expand all | Expand 10 after
672 screenshot=False, verbose=False, tool=None, 672 screenshot=False, verbose=False, tool=None,
673 apk_package=None, 673 apk_package=None,
674 host_driven_root=None, # unused? 674 host_driven_root=None, # unused?
675 official_build=False, 675 official_build=False,
676 json_results_file=None, 676 json_results_file=None,
677 timeout_scale=None, strict_mode=None, 677 timeout_scale=None, strict_mode=None,
678 suffix=None, num_retries=None, 678 suffix=None, num_retries=None,
679 device_flags=None, 679 device_flags=None,
680 wrapper_script_suite_name=None, 680 wrapper_script_suite_name=None,
681 **kwargs): 681 **kwargs):
682 logcat_output_file = self.m.raw_io.output()
683 args = [ 682 args = [
684 '--blacklist-file', self.blacklist_file, 683 '--blacklist-file', self.blacklist_file,
685 '--logcat-output-file', logcat_output_file,
686 ] 684 ]
687 if tool: 685 if tool:
688 args.append('--tool=%s' % tool) 686 args.append('--tool=%s' % tool)
689 if flakiness_dashboard: 687 if flakiness_dashboard:
690 args.extend(['--flakiness-dashboard-server', flakiness_dashboard]) 688 args.extend(['--flakiness-dashboard-server', flakiness_dashboard])
691 if annotation: 689 if annotation:
692 args.extend(['-A', annotation]) 690 args.extend(['-A', annotation])
693 if except_annotation: 691 if except_annotation:
694 args.extend(['-E', except_annotation]) 692 args.extend(['-E', except_annotation])
695 if screenshot: 693 if screenshot:
(...skipping 29 matching lines...) Expand all
725 args.append('--release') 723 args.append('--release')
726 if official_build: 724 if official_build:
727 args.extend(['--official-build']) 725 args.extend(['--official-build'])
728 726
729 step_result = self.test_runner( 727 step_result = self.test_runner(
730 'Instrumentation test %s%s' % (annotation or name, 728 'Instrumentation test %s%s' % (annotation or name,
731 ' (%s)' % suffix if suffix else ''), 729 ' (%s)' % suffix if suffix else ''),
732 args=args, 730 args=args,
733 wrapper_script_suite_name=wrapper_script_suite_name, 731 wrapper_script_suite_name=wrapper_script_suite_name,
734 **kwargs) 732 **kwargs)
735 if step_result.raw_io.output:
736 step_result.presentation.logs['logcat'] = (
737 step_result.raw_io.output.splitlines())
738 return step_result 733 return step_result
739 734
740 def launch_gce_instances(self, snapshot='clean-17-l-phone-image-no-popups', 735 def launch_gce_instances(self, snapshot='clean-17-l-phone-image-no-popups',
741 count=6): 736 count=6):
742 args = [ 737 args = [
743 self.m.properties['slavename'], 738 self.m.properties['slavename'],
744 self.m.adb.adb_path(), 739 self.m.adb.adb_path(),
745 '--n', count, 740 '--n', count,
746 'launch', 741 'launch',
747 '--snapshot', snapshot, 742 '--snapshot', snapshot,
(...skipping 514 matching lines...) Expand 10 before | Expand all | Expand 10 after
1262 script = self.c.test_runner 1257 script = self.c.test_runner
1263 if wrapper_script_suite_name: 1258 if wrapper_script_suite_name:
1264 script = self.m.chromium.output_dir.join('bin', 'run_%s' % 1259 script = self.m.chromium.output_dir.join('bin', 'run_%s' %
1265 wrapper_script_suite_name) 1260 wrapper_script_suite_name)
1266 else: 1261 else:
1267 env = kwargs.get('env', {}) 1262 env = kwargs.get('env', {})
1268 env['CHROMIUM_OUTPUT_DIR'] = env.get('CHROMIUM_OUTPUT_DIR', 1263 env['CHROMIUM_OUTPUT_DIR'] = env.get('CHROMIUM_OUTPUT_DIR',
1269 self.m.chromium.output_dir) 1264 self.m.chromium.output_dir)
1270 kwargs['env'] = env 1265 kwargs['env'] = env
1271 return self.m.python(step_name, script, args, **kwargs) 1266 return self.m.python(step_name, script, args, **kwargs)
OLDNEW
« no previous file with comments | « no previous file | scripts/slave/recipe_modules/chromium_android/example.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698