Index: third_party/gtest-parallel/gtest-parallel |
diff --git a/third_party/gtest-parallel/gtest-parallel b/third_party/gtest-parallel/gtest-parallel |
index 4e80928df659269eca75f169dbefc2f545c83025..10e7452b4dd39ca219c089b9120ec71f89388d08 100755 |
--- a/third_party/gtest-parallel/gtest-parallel |
+++ b/third_party/gtest-parallel/gtest-parallel |
@@ -1,4 +1,4 @@ |
-#!/usr/bin/env python2 |
+#!/usr/bin/env python |
# Copyright 2013 Google Inc. All rights reserved. |
# |
# Licensed under the Apache License, Version 2.0 (the "License"); |
@@ -321,6 +321,11 @@ for test_binary in binaries: |
tests.append((times.get_test_time(test_binary, test), |
test_binary, test, command)) |
+shard_count = int(os.environ.get('GTEST_TOTAL_SHARDS', 1)) |
kjellander_webrtc
2016/11/15 15:13:36
Since this is both ugly and hard to know, could we
|
+shard_run = int(os.environ.get('GTEST_SHARD_INDEX', 0)) |
+ |
+tests = tests[shard_run::shard_count] |
+ |
if options.failed: |
# The first element of each entry is the runtime of the most recent |
# run if it was successful, or None if the test is new or the most |