### Question:
ProcessWorker implements Worker { public void destroy() { try { Thread.sleep(100); } catch (InterruptedException e) { throw new UncheckedInterruptedException(e); } m_process.destroy(); } ProcessWorker(WorkerIdentity workerIdentity,
                       CommandLine commandLine,
                       OutputStream outputStream,
                       OutputStream errorStream); WorkerIdentity getIdentity(); OutputStream getCommunicationStream(); int waitFor(); void destroy();  }### Answer:
@Test public void testDestroy() throws Exception { final CommandLine commandLine = new MyCommandLine("java", "-classpath", s_testClasspath, EchoClass.class.getName()); final ProcessWorker childProcess = new ProcessWorker(m_agentIdentity.createWorkerIdentity(), commandLine, m_outputStream, m_errorStream); childProcess.destroy(); childProcess.waitFor(); }