title: Coverage report in Java 8
body: <p>I have just started working with Java 8. I see a lot of streams and optionals. One question popped in my mind. Consider the following example taken from <a href="http://www.oracle.com/technetwork/articles/java/java8-optional-2175753.html">this oracle tutorial</a>:</p>
  
  <pre><code>String name = computer.flatMap(Computer::getSoundcard)
                            .flatMap(Soundcard::getUSB)
                            .map(USB::getVersion)
                            .orElse("UNKNOWN");
  </code></pre>
  
  <p>Or the next one taken from <a href="http://winterbe.com/posts/2014/07/31/java8-stream-tutorial-examples/">here</a>:</p>
  
  <pre><code>List&lt;String&gt; myList = new ArrayList();
  
  myList
      .stream()
      .filter(s -&gt; s.startsWith("c"))
      .map(String::toUpperCase)
      .sorted()
      .forEach(System.out::println);
  </code></pre>
  
  <p>Is there any coverage solution, which can tell me if the <code>orElse</code> in the first snippet was used? Or some other, which tells me that the <code>filter</code> closure was not called at all, since the list was empty? Can any report, that the method reference in <code>forEach</code> was not used?</p>