Make `SkyframeLookupResult` and `SkyframeIterableResult` interfaces.

In a followup, `SkyFunctionEnvironment` will use its own implementation of these interfaces which does not require constructing a temporary map or list. The existing implementations are prefixed with `Simple` and are still in use in this change, but will be made test-only in the followup.

PiperOrigin-RevId: 477051692
Change-Id: I925b49f957d36dfdc3bc20e295d0728e686a04a9
diff --git a/src/test/java/com/google/devtools/build/lib/skyframe/TransitiveTraversalFunctionTest.java b/src/test/java/com/google/devtools/build/lib/skyframe/TransitiveTraversalFunctionTest.java
index 37c1e14..73033aa 100644
--- a/src/test/java/com/google/devtools/build/lib/skyframe/TransitiveTraversalFunctionTest.java
+++ b/src/test/java/com/google/devtools/build/lib/skyframe/TransitiveTraversalFunctionTest.java
@@ -28,6 +28,7 @@
 import com.google.devtools.build.lib.skyframe.util.SkyframeExecutorTestUtils;
 import com.google.devtools.build.lib.util.GroupedList;
 import com.google.devtools.build.skyframe.EvaluationResult;
+import com.google.devtools.build.skyframe.SimpleSkyframeLookupResult;
 import com.google.devtools.build.skyframe.SkyFunction;
 import com.google.devtools.build.skyframe.SkyKey;
 import com.google.devtools.build.skyframe.SkyframeLookupResult;
@@ -80,7 +81,7 @@
               wasOptimizationUsed.set(true);
               // It doesn't matter what this SkyframeLookupResult is, we'll return true in the
               // valuesMissing() call.
-              return new SkyframeLookupResult(
+              return new SimpleSkyframeLookupResult(
                   /* valuesMissingCallback= */ () -> {},
                   k -> {
                     throw new IllegalStateException("Shouldn't have been called: " + k);
@@ -119,7 +120,7 @@
     NoSuchTargetException exp1 = new NoSuchTargetException("bad bar");
     NoSuchTargetException exp2 = new NoSuchTargetException("bad baz");
     SkyframeLookupResult returnedDeps =
-        new SkyframeLookupResult(
+        new SimpleSkyframeLookupResult(
             () -> {},
             key ->
                 key.equals(dep1)
@@ -155,7 +156,7 @@
     SkyKey dep = function.getKey(Label.parseCanonical("//foo:bar"));
     NoSuchTargetException exp = new NoSuchTargetException("bad bar");
     SkyframeLookupResult returnedDep =
-        new SkyframeLookupResult(
+        new SimpleSkyframeLookupResult(
             () -> {}, key -> key.equals(dep) ? ValueOrUntypedException.ofExn(exp) : null);
     SkyFunction.Environment mockEnv = Mockito.mock(SkyFunction.Environment.class);
     when(mockEnv.getValuesAndExceptions(ImmutableSet.of(dep))).thenReturn(returnedDep);
@@ -208,7 +209,7 @@
     NoSuchTargetException exp = new NoSuchTargetException("bad test");
     AtomicBoolean valuesMissing = new AtomicBoolean(false);
     SkyframeLookupResult returnedDep =
-        new SkyframeLookupResult(
+        new SimpleSkyframeLookupResult(
             () -> valuesMissing.set(true),
             key -> key.equals(badDep) ? ValueOrUntypedException.ofExn(exp) : null);
     SkyFunction.Environment mockEnv = Mockito.mock(SkyFunction.Environment.class);