diff options
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/exec/TestStrategy.java')
-rw-r--r-- | src/main/java/com/google/devtools/build/lib/exec/TestStrategy.java | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/exec/TestStrategy.java b/src/main/java/com/google/devtools/build/lib/exec/TestStrategy.java index 0a29b9f89d..7d98a9a942 100644 --- a/src/main/java/com/google/devtools/build/lib/exec/TestStrategy.java +++ b/src/main/java/com/google/devtools/build/lib/exec/TestStrategy.java @@ -32,6 +32,7 @@ import com.google.devtools.build.lib.rules.test.TestActionContext; import com.google.devtools.build.lib.rules.test.TestResult; import com.google.devtools.build.lib.rules.test.TestRunnerAction; import com.google.devtools.build.lib.rules.test.TestTargetExecutionSettings; +import com.google.devtools.build.lib.util.Fingerprint; import com.google.devtools.build.lib.util.OS; import com.google.devtools.build.lib.util.io.FileWatcher; import com.google.devtools.build.lib.util.io.OutErr; @@ -262,6 +263,14 @@ public abstract class TestStrategy implements TestActionContext { } } + protected String getTmpDirName(PathFragment execPath, int shard, int run) { + Fingerprint digest = new Fingerprint(); + digest.addPath(execPath); + digest.addInt(shard); + digest.addInt(run); + return digest.hexDigestAndReset(); + } + /** Parse a test result XML file into a {@link TestCase}. */ @Nullable protected TestCase parseTestResult(Path resultFile) { |