diff --git a/src/test/java/com/google/devtools/build/lib/remote/RemoteSpawnCacheTest.java b/src/test/java/com/google/devtools/build/lib/remote/RemoteSpawnCacheTest.java index 61ce8de1bd9734..4171d01fe5b763 100644 --- a/src/test/java/com/google/devtools/build/lib/remote/RemoteSpawnCacheTest.java +++ b/src/test/java/com/google/devtools/build/lib/remote/RemoteSpawnCacheTest.java @@ -143,7 +143,7 @@ public MetadataProvider getMetadataProvider() { @Override public ArtifactExpander getArtifactExpander() { - return SIMPLE_ARTIFACT_EXPANDER; + throw new UnsupportedOperationException(); } @Override diff --git a/src/test/java/com/google/devtools/build/lib/remote/RemoteSpawnRunnerTest.java b/src/test/java/com/google/devtools/build/lib/remote/RemoteSpawnRunnerTest.java index 81bbc05a481c43..68fce99846b68b 100644 --- a/src/test/java/com/google/devtools/build/lib/remote/RemoteSpawnRunnerTest.java +++ b/src/test/java/com/google/devtools/build/lib/remote/RemoteSpawnRunnerTest.java @@ -74,7 +74,6 @@ 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; @@ -1268,7 +1267,6 @@ 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( @@ -1312,7 +1310,6 @@ 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( @@ -1356,7 +1353,6 @@ 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( @@ -1417,7 +1413,6 @@ 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( @@ -1466,7 +1461,6 @@ 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( @@ -1516,7 +1510,6 @@ 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(