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

Side by Side Diff: build/android/pylib/utils/report_results.py

Issue 15942016: Creates a new test running script test_runner.py (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Renames run_all_tests.py to test_runner.py Created 7 years, 5 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
OLDNEW
1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 # Copyright (c) 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 """Module containing utility functions for reporting results.""" 5 """Module containing utility functions for reporting results."""
6 6
7 import logging 7 import logging
8 import os 8 import os
9 import re 9 import re
10 10
(...skipping 25 matching lines...) Expand all
36 results.GetShortForm()) 36 results.GetShortForm())
37 37
38 38
39 def _LogToFlakinessDashboard(results, test_type, test_package, 39 def _LogToFlakinessDashboard(results, test_type, test_package,
40 flakiness_server): 40 flakiness_server):
41 """Upload results to the flakiness dashboard""" 41 """Upload results to the flakiness dashboard"""
42 logging.info('Upload results for test type "%s", test package "%s" to %s' % 42 logging.info('Upload results for test type "%s", test package "%s" to %s' %
43 (test_type, test_package, flakiness_server)) 43 (test_type, test_package, flakiness_server))
44 44
45 # TODO(frankf): Enable uploading for gtests. 45 # TODO(frankf): Enable uploading for gtests.
46 if test_type != 'Instrumentation': 46 if test_type not in ['Instrumentation', 'HostDriven']:
frankf 2013/07/02 20:51:10 This is no longer needed right?
gkanwar 2013/07/02 21:16:14 Ah good catch. Fixed.
47 logging.warning('Invalid test type.') 47 logging.warning('Invalid test type.')
48 return 48 return
49 49
50 try: 50 try:
51 if flakiness_server == constants.UPSTREAM_FLAKINESS_SERVER: 51 if flakiness_server == constants.UPSTREAM_FLAKINESS_SERVER:
52 assert test_package in ['ContentShellTest', 52 assert test_package in ['ContentShellTest',
53 'ChromiumTestShellTest', 53 'ChromiumTestShellTest',
54 'AndroidWebViewTest'] 54 'AndroidWebViewTest']
55 dashboard_test_type = ('%s_instrumentation_tests' % 55 dashboard_test_type = ('%s_instrumentation_tests' %
56 test_package.lower().rstrip('test')) 56 test_package.lower().rstrip('test'))
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 _LogToFlakinessDashboard(results, test_type, test_package, 111 _LogToFlakinessDashboard(results, test_type, test_package,
112 flakiness_server) 112 flakiness_server)
113 113
114 114
115 def PrintAnnotation(results): 115 def PrintAnnotation(results):
116 """Print buildbot annotations for test results.""" 116 """Print buildbot annotations for test results."""
117 if not results.DidRunPass(): 117 if not results.DidRunPass():
118 buildbot_report.PrintError() 118 buildbot_report.PrintError()
119 else: 119 else:
120 print 'Step success!' # No annotation needed 120 print 'Step success!' # No annotation needed
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698