@Nullable
    @Override
    public Void answer(InvocationOnMock invocation) throws Throwable {
      Consumer consumer = (Consumer) invocation.getArguments()[0];
      Iterator<CloseableReference<CloseableImage>> iterator = mResults.iterator();
      while (iterator.hasNext()) {
        CloseableReference<CloseableImage> result = iterator.next();
        consumer.onNewResult(
            result, iterator.hasNext() ? mStatusFlags : Consumer.IS_LAST | mStatusFlags);
      }
      return null;
    }
Verify that stateful image results, both intermediate and final, are never cached.
imagepipeline/src/test/java/com/facebook/imagepipeline/producers/BitmapMemoryCacheProducerTest.java