### Question:
RenderChecker { public boolean areRendered(Collection<ViewController> components) { return reduce(components, true, ViewController::isRendered); }  boolean areRendered(Collection<ViewController> components);  }### Answer:
@Test public void areRendered() { Collection<ViewController> items = Arrays.asList( renderedComponent(), renderedComponent(), renderedComponent() ); assertThat(uut.areRendered(items)).isTrue(); forEach(items, i -> verify(i).isRendered()); }
@Test public void areRendered_reduce() { Collection<ViewController> items = Arrays.asList( renderedComponent(), notRenderedComponent(), renderedComponent() ); assertThat(uut.areRendered(items)).isFalse(); }