Skip to content

Commit b0db044

Browse files
lberkicopybara-github
authored andcommitted
Add tree artifact metadata for the coverage post-processing spawn.
This makes --experimental_split_coverage_postprocessing work in the wake of fb6658c: before, it was enough to add the metadata of the tree file artifacts to the metadata provider of the post-processing action, but that change made the metadata of the tree artifact necessary, too. Progress towards #20753. RELNOTES: None. PiperOrigin-RevId: 596929659 Change-Id: I481ef36328de7f7ab07f2ec7a0ac83d5fd508c36
1 parent 1d4ab4d commit b0db044

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

src/main/java/com/google/devtools/build/lib/exec/StandaloneTestStrategy.java

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -738,6 +738,12 @@ private TestAttemptResult runTestAttempt(
738738
.getOutputMetadataStore()
739739
.getTreeArtifactChildren(
740740
(SpecialArtifact) testAction.getCoverageDirectoryTreeArtifact());
741+
ImmutableSet<ActionInput> coverageSpawnMetadata =
742+
ImmutableSet.<ActionInput>builder()
743+
.addAll(expandedCoverageDir)
744+
.add(testAction.getCoverageDirectoryTreeArtifact())
745+
.build();
746+
741747
Spawn coveragePostProcessingSpawn =
742748
createCoveragePostProcessingSpawn(
743749
actionExecutionContext,
@@ -757,7 +763,7 @@ private TestAttemptResult runTestAttempt(
757763
ActionExecutionContext coverageActionExecutionContext =
758764
actionExecutionContext
759765
.withFileOutErr(coverageOutErr)
760-
.withOutputsAsInputs(expandedCoverageDir);
766+
.withOutputsAsInputs(coverageSpawnMetadata);
761767

762768
writeOutFile(coverageOutErr.getErrorPath(), coverageOutErr.getOutputPath());
763769
appendCoverageLog(coverageOutErr, fileOutErr);

0 commit comments

Comments
 (0)