### Question:
ProcessHelper { void doEndProcess(Process process, boolean checkTerminatedProcess) { boolean terminated = !checkTerminatedProcess; if (checkTerminatedProcess) { try { process.exitValue(); terminated = true; } catch (IllegalThreadStateException e) { terminated = false; } } if (terminated) { Span span = inFlightSpans.remove(process); if (span != null) { span.end(); } } } ProcessHelper(WeakConcurrentMap<Process, Span> inFlightSpans);   }### Answer:
@Test void endUntrackedProcess() { Process process = mock(Process.class); helper.doEndProcess(process, true); }