### Question:
VerifierWebWorkerConnectionImpl implements VerifierWebWorkerConnection { @Override public void activate() { receiver.activate(); if (worker == null) { startWorker(); poster.post(initialize); } else { poster.post(new RequestStatus()); } } VerifierWebWorkerConnectionImpl(final Initialize initialize,
                                           final String pathToVerifier,
                                           final Poster poster,
                                           final Receiver receiver); @Override void activate(); @Override void terminate();  }### Answer:
@Test public void firstActivationStartWebWorker() throws Exception { verifierWebWorkerConnection.activate(); verify(receiver).activate(); verify(receiver).setUp(any()); verify(poster).setUp(any()); verify(poster).post(any(Initialize.class)); }
@Test public void secondActivationDoesNotStartWebWorker() throws Exception { verifierWebWorkerConnection.activate(); reset(receiver, poster); verifierWebWorkerConnection.activate(); verify(receiver).activate(); verify(receiver, never()).setUp(any()); verify(poster, never()).setUp(any()); verify(poster).post(any(RequestStatus.class)); }