OLD | NEW |
1 #!/usr/bin/python | 1 # Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 # Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. | |
3 # 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 |
4 # found in the LICENSE file. | 3 # found in the LICENSE file. |
5 | 4 |
6 """Platform-specific utility methods shared by several scripts.""" | 5 """Platform-specific utility methods shared by several scripts.""" |
7 | 6 |
8 import os | 7 import os |
9 import subprocess | 8 import subprocess |
10 | 9 |
11 import google.path_utils | 10 import google.path_utils |
12 | 11 |
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
135 """Returns a list of strings that contains the command line+args needed to | 134 """Returns a list of strings that contains the command line+args needed to |
136 stop the http server used in the http tests. | 135 stop the http server used in the http tests. |
137 | 136 |
138 This tries to fetch the pid of httpd (if available) and returns the | 137 This tries to fetch the pid of httpd (if available) and returns the |
139 command to kill it. If pid is not available, kill all httpd processes | 138 command to kill it. If pid is not available, kill all httpd processes |
140 """ | 139 """ |
141 | 140 |
142 if not self._httpd_cmd_string: | 141 if not self._httpd_cmd_string: |
143 return ["true"] # Haven't been asked for the start cmd yet. Just pass. | 142 return ["true"] # Haven't been asked for the start cmd yet. Just pass. |
144 return [self._bash, "-c", self._httpd_cmd_string + ' -k stop'] | 143 return [self._bash, "-c", self._httpd_cmd_string + ' -k stop'] |
OLD | NEW |