### Question:
ZipkinTracer extends AbstractTracer { @Override public void endCall(RequestUUID uuid, RequestUUID subUuid, OperationKey operationKey) { ZipkinData zipkinData = getZipkinDataIfReady(subUuid); if (zipkinData != null) { zipkinEmitter.emitClientReceive(zipkinData); } }  @Override void start(RequestUUID uuid, OperationKey operationKey); @Override void trace(RequestUUID uuid, String msg); @Override void trace(RequestUUID uuid, String msg, Object arg1); @Override void trace(RequestUUID uuid, String msg, Object arg1, Object arg2); @Override void trace(RequestUUID uuid, String msg, Object arg1, Object arg2, Object arg3); @Override void trace(RequestUUID uuid, String msg, Object... args); @Override void end(RequestUUID uuid); @Override void startCall(RequestUUID uuid, RequestUUID subUuid, OperationKey operationKey); @Override void endCall(RequestUUID uuid, RequestUUID subUuid, OperationKey operationKey); void setZipkinEmitter(@Nonnull ZipkinEmitter zipkinEmitter);  }### Answer:
@Test public void endCall_WhenZipkinTracingIsReady_ShouldEmitClientReceive() { when(requestUUID.isZipkinTracingReady()).thenReturn(true); when(requestUUID.getZipkinData()).thenReturn(zipkinData); victim.endCall(null, requestUUID, null); verify(zipkinEmitter).emitClientReceive(zipkinData); }
@Test public void endCall_WhenZipkinTracingIsNotReady_ShouldNotEmitAnything() { when(requestUUID.isZipkinTracingReady()).thenReturn(false); victim.endCall(null, requestUUID, null); verifyZeroInteractions(zipkinEmitter); }