aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib/worker
diff options
context:
space:
mode:
authorGravatar ruperts <ruperts@google.com>2017-10-07 00:46:20 +0200
committerGravatar Klaus Aehlig <aehlig@google.com>2017-10-07 11:07:30 +0200
commit4050a89a1e3fb6a9a9c6bd080cf4e3081a9f2012 (patch)
tree0df531d72015ad33f3a6c8ff670846808714e8bd /src/main/java/com/google/devtools/build/lib/worker
parent5f39475bb51f48182180e34e4310edb650bea462 (diff)
More SpawnResult-related plumbing changes to Actions, Strategies, ActionContexts, etc., so that SpawnResult metadata is returned upwards.
Note that the TODOs mostly refer to changes that will appear in a subsequent CL (a CL to return SpawnResults, contained in ActionResults, from Actions/AbstractActions). I split off the remaining SpawnResult-related changes into this CL and kept the ActionResult-related changes separate. RELNOTES: None. PiperOrigin-RevId: 171355611
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/worker')
-rw-r--r--src/main/java/com/google/devtools/build/lib/worker/WorkerTestStrategy.java11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/worker/WorkerTestStrategy.java b/src/main/java/com/google/devtools/build/lib/worker/WorkerTestStrategy.java
index e9d7dee66f..e06b6c4f1b 100644
--- a/src/main/java/com/google/devtools/build/lib/worker/WorkerTestStrategy.java
+++ b/src/main/java/com/google/devtools/build/lib/worker/WorkerTestStrategy.java
@@ -30,6 +30,7 @@ import com.google.devtools.build.lib.analysis.test.TestActionContext;
import com.google.devtools.build.lib.analysis.test.TestRunnerAction;
import com.google.devtools.build.lib.events.Event;
import com.google.devtools.build.lib.exec.ExecutionOptions;
+import com.google.devtools.build.lib.exec.StandaloneTestResult;
import com.google.devtools.build.lib.exec.StandaloneTestStrategy;
import com.google.devtools.build.lib.runtime.CommandEnvironment;
import com.google.devtools.build.lib.vfs.Path;
@@ -76,10 +77,8 @@ public class WorkerTestStrategy extends StandaloneTestStrategy {
}
@Override
- protected TestResultData executeTest(
- TestRunnerAction action,
- Spawn spawn,
- ActionExecutionContext actionExecutionContext)
+ protected StandaloneTestResult executeTest(
+ TestRunnerAction action, Spawn spawn, ActionExecutionContext actionExecutionContext)
throws ExecException, InterruptedException, IOException {
if (!action.getConfiguration().compatibleWithStrategy("experimental_worker")) {
throw new UserExecException(
@@ -108,7 +107,7 @@ public class WorkerTestStrategy extends StandaloneTestStrategy {
actionExecutionContext.getExecRoot());
}
- private TestResultData execInWorker(
+ private StandaloneTestResult execInWorker(
TestRunnerAction action,
Spawn spawn,
ActionExecutionContext actionExecutionContext,
@@ -214,7 +213,7 @@ public class WorkerTestStrategy extends StandaloneTestStrategy {
builder.setTestCase(details);
}
- return builder.build();
+ return StandaloneTestResult.create(ImmutableSet.of(), builder.build());
} catch (IOException | InterruptedException e) {
if (worker != null) {
workerPool.invalidateObject(key, worker);