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

Side by Side Diff: mojo/devtools/common/devtoolslib/apptest_gtest.py

Issue 1268713005: Unify method name casing in devtools. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 4 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 2014 The Chromium Authors. All rights reserved. 1 # Copyright 2014 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 """Apptest runner specific to the particular gtest-based apptest framework in 5 """Apptest runner specific to the particular gtest-based apptest framework in
6 /mojo/public/cpp/application/tests/, built on top of the general apptest 6 /mojo/public/cpp/application/tests/, built on top of the general apptest
7 runner.""" 7 runner."""
8 8
9 import logging 9 import logging
10 import re 10 import re
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 An empty list is returned on failure, with errors logged. 72 An empty list is returned on failure, with errors logged.
73 73
74 Args: 74 Args:
75 apptest: The URL of the test application to run. 75 apptest: The URL of the test application to run.
76 """ 76 """
77 arguments = [] 77 arguments = []
78 arguments.extend(shell_args) 78 arguments.extend(shell_args)
79 arguments.append("--args-for=%s %s" % (apptest, "--gtest_list_tests")) 79 arguments.append("--args-for=%s %s" % (apptest, "--gtest_list_tests"))
80 arguments.append(apptest) 80 arguments.append(apptest)
81 81
82 (exit_code, output, did_time_out) = shell.RunAndGetOutput(arguments) 82 (exit_code, output, did_time_out) = shell.run_and_get_output(arguments)
83 if exit_code or did_time_out: 83 if exit_code or did_time_out:
84 command_line = "mojo_shell " + " ".join(["%r" % x for x in arguments]) 84 command_line = "mojo_shell " + " ".join(["%r" % x for x in arguments])
85 print "Failed to get test fixtures: %r" % command_line 85 print "Failed to get test fixtures: %r" % command_line
86 print 72 * '-' 86 print 72 * '-'
87 print output 87 print output
88 print 72 * '-' 88 print 72 * '-'
89 return [] 89 return []
90 90
91 _logger.debug("Tests listed:\n%s" % output) 91 _logger.debug("Tests listed:\n%s" % output)
92 return _gtest_list_tests(output) 92 return _gtest_list_tests(output)
(...skipping 18 matching lines...) Expand all
111 test_list = [] 111 test_list = []
112 for line in output_lines: 112 for line in output_lines:
113 if not line: 113 if not line:
114 continue 114 continue
115 if line[0] != " ": 115 if line[0] != " ":
116 suite = line.strip() 116 suite = line.strip()
117 continue 117 continue
118 test_list.append(suite + line.strip()) 118 test_list.append(suite + line.strip())
119 119
120 return test_list 120 return test_list
OLDNEW
« no previous file with comments | « mojo/devtools/common/devtoolslib/apptest.py ('k') | mojo/devtools/common/devtoolslib/http_server.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698