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

Side by Side Diff: build/android/pylib/local/device/local_device_gtest_run.py

Issue 1970663002: [Android] Tweak timeout for listing gtests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 import collections 5 import collections
6 import itertools 6 import itertools
7 import os 7 import os
8 import posixpath 8 import posixpath
9 9
10 from devil.android import device_errors 10 from devil.android import device_errors
(...skipping 294 matching lines...) Expand 10 before | Expand all | Expand 10 after
305 if tests: 305 if tests:
306 return tests 306 return tests
307 307
308 # Even when there's only one device, it still makes sense to retrieve the 308 # Even when there's only one device, it still makes sense to retrieve the
309 # test list so that tests can be split up and run in batches rather than all 309 # test list so that tests can be split up and run in batches rather than all
310 # at once (since test output is not streamed). 310 # at once (since test output is not streamed).
311 @local_device_test_run.handle_shard_failures_with( 311 @local_device_test_run.handle_shard_failures_with(
312 on_failure=self._env.BlacklistDevice) 312 on_failure=self._env.BlacklistDevice)
313 def list_tests(dev): 313 def list_tests(dev):
314 tests = self._delegate.Run( 314 tests = self._delegate.Run(
315 None, dev, flags='--gtest_list_tests', timeout=20) 315 None, dev, flags='--gtest_list_tests', timeout=30)
316 tests = gtest_test_instance.ParseGTestListTests(tests) 316 tests = gtest_test_instance.ParseGTestListTests(tests)
317 tests = self._test_instance.FilterTests(tests) 317 tests = self._test_instance.FilterTests(tests)
318 return tests 318 return tests
319 319
320 # Query all devices in case one fails. 320 # Query all devices in case one fails.
321 test_lists = self._env.parallel_devices.pMap(list_tests).pGet(None) 321 test_lists = self._env.parallel_devices.pMap(list_tests).pGet(None)
322 322
323 # If all devices failed to list tests, raise an exception. 323 # If all devices failed to list tests, raise an exception.
324 # Check that tl is not None and is not empty. 324 # Check that tl is not None and is not empty.
325 if all(not tl for tl in test_lists): 325 if all(not tl for tl in test_lists):
(...skipping 30 matching lines...) Expand all
356 def TearDown(self): 356 def TearDown(self):
357 @local_device_test_run.handle_shard_failures 357 @local_device_test_run.handle_shard_failures
358 def individual_device_tear_down(dev): 358 def individual_device_tear_down(dev):
359 for s in self._servers.get(str(dev), []): 359 for s in self._servers.get(str(dev), []):
360 s.TearDown() 360 s.TearDown()
361 361
362 tool = self.GetTool(dev) 362 tool = self.GetTool(dev)
363 tool.CleanUpEnvironment() 363 tool.CleanUpEnvironment()
364 364
365 self._env.parallel_devices.pMap(individual_device_tear_down) 365 self._env.parallel_devices.pMap(individual_device_tear_down)
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698