Add sharding logic to android's test runner |
|||
Issue descriptionThat is, allow it to shard a suite of tests across multiple invocations of the test runner. This would allow for swarming to shard a single android suite N times and run them in parallel. This would come in handy when all android bots are swarmed at a per-device level. An entire chrome_public suite would take too long on a single device. From offline talk with jbudorick@: Much like the desktop test runner, we'd probably want to add a --shard-num and --max-shard args and have some fancy hashing algorithm in the test harness determine which of a suite's tests to run based on those two values.
,
Feb 14 2017
Ideally, for gtests, this would transparently pass the flags into the test launcher. I'm not sure if that will work currently, though, as it depends on both whether Android gets to that part of the test launcher and how --gtest_list_tests behaves with the two sharding arguments.
,
Feb 14 2017
That said, we'll still need to implement this logic in the test runner for instrumentation tests.
,
Mar 6 2017
Any plans as of yet? I'd love to see some dope sharding in use on https://build.chromium.org/p/chromium.swarm/builders/Android%20Swarm
,
Mar 6 2017
I'll do this this week.
,
Mar 15 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/84188b5c73a3bd70944aac7028dbdd449e9e5b73 commit 84188b5c73a3bd70944aac7028dbdd449e9e5b73 Author: jbudorick <jbudorick@chromium.org> Date: Wed Mar 15 05:29:24 2017 [Android] Add support for external sharding to the test runner. This adds support for sharding via GTEST_SHARD_INDEX and GTEST_TOTAL_SHARDS (along with their equivalent --test-launcher-* command-line options), matching the behavior of //base/test/launcher for both gtests and instrumentation tests. BUG= 692200 Review-Url: https://codereview.chromium.org/2743873003 Cr-Commit-Position: refs/heads/master@{#457001} [modify] https://crrev.com/84188b5c73a3bd70944aac7028dbdd449e9e5b73/build/android/pylib/gtest/gtest_test_instance.py [modify] https://crrev.com/84188b5c73a3bd70944aac7028dbdd449e9e5b73/build/android/pylib/instrumentation/instrumentation_test_instance.py [modify] https://crrev.com/84188b5c73a3bd70944aac7028dbdd449e9e5b73/build/android/pylib/local/device/local_device_gtest_run.py [modify] https://crrev.com/84188b5c73a3bd70944aac7028dbdd449e9e5b73/build/android/pylib/local/device/local_device_instrumentation_test_run.py [modify] https://crrev.com/84188b5c73a3bd70944aac7028dbdd449e9e5b73/build/android/pylib/local/device/local_device_test_run.py [modify] https://crrev.com/84188b5c73a3bd70944aac7028dbdd449e9e5b73/build/android/test_runner.py [modify] https://crrev.com/84188b5c73a3bd70944aac7028dbdd449e9e5b73/testing/buildbot/chromium.swarm.json
,
Mar 15 2017
|
|||
►
Sign in to add a comment |
|||
Comment 1 by bpastene@chromium.org
, Feb 14 2017