Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[5.x] Fix remote spawn tests for remote_merkle_tree_cache=true #14334

Merged
merged 1 commit into from
Nov 25, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ public MetadataProvider getMetadataProvider() {

@Override
public ArtifactExpander getArtifactExpander() {
throw new UnsupportedOperationException();
return SIMPLE_ARTIFACT_EXPANDER;
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@
import com.google.devtools.build.lib.exec.RemoteLocalFallbackRegistry;
import com.google.devtools.build.lib.exec.SpawnCheckingCacheEvent;
import com.google.devtools.build.lib.exec.SpawnExecutingEvent;
import com.google.devtools.build.lib.exec.SpawnInputExpander;
import com.google.devtools.build.lib.exec.SpawnRunner;
import com.google.devtools.build.lib.exec.SpawnRunner.SpawnExecutionContext;
import com.google.devtools.build.lib.exec.SpawnSchedulingEvent;
Expand Down Expand Up @@ -1267,6 +1268,7 @@ public void shouldReportCheckingCacheBeforeScheduling() throws Exception {

Spawn spawn = newSimpleSpawn();
SpawnExecutionContext policy = mock(SpawnExecutionContext.class);
when(policy.getSpawnInputExpander()).thenReturn(mock(SpawnInputExpander.class));
when(policy.getTimeout()).thenReturn(Duration.ZERO);

when(executor.executeRemotely(
Expand Down Expand Up @@ -1310,6 +1312,7 @@ public void shouldReportExecutingStatusWithoutMetadata() throws Exception {

Spawn spawn = newSimpleSpawn();
SpawnExecutionContext policy = mock(SpawnExecutionContext.class);
when(policy.getSpawnInputExpander()).thenReturn(mock(SpawnInputExpander.class));
when(policy.getTimeout()).thenReturn(Duration.ZERO);

when(executor.executeRemotely(
Expand Down Expand Up @@ -1353,6 +1356,7 @@ public void shouldReportExecutingStatusAfterGotExecutingStageFromMetadata() thro

Spawn spawn = newSimpleSpawn();
SpawnExecutionContext policy = mock(SpawnExecutionContext.class);
when(policy.getSpawnInputExpander()).thenReturn(mock(SpawnInputExpander.class));
when(policy.getTimeout()).thenReturn(Duration.ZERO);

when(executor.executeRemotely(
Expand Down Expand Up @@ -1413,6 +1417,7 @@ public void shouldIgnoreInvalidMetadata() throws Exception {

Spawn spawn = newSimpleSpawn();
SpawnExecutionContext policy = mock(SpawnExecutionContext.class);
when(policy.getSpawnInputExpander()).thenReturn(mock(SpawnInputExpander.class));
when(policy.getTimeout()).thenReturn(Duration.ZERO);

when(executor.executeRemotely(
Expand Down Expand Up @@ -1461,6 +1466,7 @@ public void shouldReportExecutingStatusIfNoExecutingStatusFromMetadata() throws

Spawn spawn = newSimpleSpawn();
SpawnExecutionContext policy = mock(SpawnExecutionContext.class);
when(policy.getSpawnInputExpander()).thenReturn(mock(SpawnInputExpander.class));
when(policy.getTimeout()).thenReturn(Duration.ZERO);

when(executor.executeRemotely(
Expand Down Expand Up @@ -1510,6 +1516,7 @@ public void shouldReportExecutingStatusEvenNoOperationFromServer() throws Except

Spawn spawn = newSimpleSpawn();
SpawnExecutionContext policy = mock(SpawnExecutionContext.class);
when(policy.getSpawnInputExpander()).thenReturn(mock(SpawnInputExpander.class));
when(policy.getTimeout()).thenReturn(Duration.ZERO);

when(executor.executeRemotely(
Expand Down