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

Side by Side Diff: tools/bisect-manual-test.py

Issue 277993002: Add target_build_type flag to bisect-perf-regression tool to enable bisecting of a Debug build with… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 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 | tools/bisect-perf-regression.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 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # Copyright 2013 The Chromium Authors. All rights reserved. 2 # Copyright 2013 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 5
6 """Simple script which asks user to manually check result of bisection. 6 """Simple script which asks user to manually check result of bisection.
7 7
8 Typically used as by the run-bisect-manual-test.py script. 8 Typically used as by the run-bisect-manual-test.py script.
9 """ 9 """
10 10
11 import os 11 import os
12 import sys 12 import sys
13 13
14 sys.path.append(os.path.join(os.path.dirname(__file__), 'telemetry')) 14 sys.path.append(os.path.join(os.path.dirname(__file__), 'telemetry'))
15 from telemetry.core import browser_finder 15 from telemetry.core import browser_finder
16 from telemetry.core import browser_options 16 from telemetry.core import browser_options
17 17
18 18
19 def _StartManualTest(options): 19 def _StartManualTest(options):
20 """Start browser then ask the user whether build is good or bad.""" 20 """Start browser then ask the user whether build is good or bad."""
21 browser_to_create = browser_finder.FindBrowser(options) 21 browser_to_create = browser_finder.FindBrowser(options)
22 print 'Starting browser: %s.' % options.browser_type 22 print 'Starting browser: %s.' % options.browser_type
23 with browser_to_create.Create() as browser: 23 with browser_to_create.Create() as browser:
24 browser.Start();
25
26 # Loop until we get a response that we can parse. 24 # Loop until we get a response that we can parse.
27 while True: 25 while True:
28 sys.stderr.write('Revision is [(g)ood/(b)ad]: ') 26 sys.stderr.write('Revision is [(g)ood/(b)ad]: ')
29 response = raw_input() 27 response = raw_input()
30 if response and response in ('g', 'b'): 28 if response and response in ('g', 'b'):
31 if response in ('g'): 29 if response in ('g'):
32 print "RESULT manual_test: manual_test= 1" 30 print "RESULT manual_test: manual_test= 1"
33 else: 31 else:
34 print "RESULT manual_test: manual_test= 0" 32 print "RESULT manual_test: manual_test= 0"
35 break 33 break
36 34
37 browser.Close()
38
39
40 def main(): 35 def main():
41 usage = ('%prog [options]\n' 36 usage = ('%prog [options]\n'
42 'Starts browser with an optional url and asks user whether ' 37 'Starts browser with an optional url and asks user whether '
43 'revision is good or bad.\n') 38 'revision is good or bad.\n')
44 39
45 options = browser_options.BrowserFinderOptions() 40 options = browser_options.BrowserFinderOptions()
46 parser = options.CreateParser(usage) 41 parser = options.CreateParser(usage)
47 options, args = parser.parse_args() 42 options, args = parser.parse_args()
48 43
49 _StartManualTest(options) 44 _StartManualTest(options)
50 45
51 46
52 if __name__ == '__main__': 47 if __name__ == '__main__':
53 sys.exit(main()) 48 sys.exit(main())
OLDNEW
« no previous file with comments | « no previous file | tools/bisect-perf-regression.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698