@Test public void deleteEncounterForOwnEncounterShouldSucceed() { doNothing().when(repository).delete(1l); service.deleteConfirmation("test", 1); }
public void deleteConfirmation(@NonNull final String username, final long confirmationId) { repository.delete(confirmationId); log.warn(SecurityMarkers.SECURITY_AUDIT, "User {} deleted confirmation {}", username, confirmationId); }
ConfirmationService { public void deleteConfirmation(@NonNull final String username, final long confirmationId) { repository.delete(confirmationId); log.warn(SecurityMarkers.SECURITY_AUDIT, "User {} deleted confirmation {}", username, confirmationId); } }
ConfirmationService { public void deleteConfirmation(@NonNull final String username, final long confirmationId) { repository.delete(confirmationId); log.warn(SecurityMarkers.SECURITY_AUDIT, "User {} deleted confirmation {}", username, confirmationId); }  }
ConfirmationService { public void deleteConfirmation(@NonNull final String username, final long confirmationId) { repository.delete(confirmationId); log.warn(SecurityMarkers.SECURITY_AUDIT, "User {} deleted confirmation {}", username, confirmationId); }  List<Confirmation> getConfirmationsByUsername(@NonNull final String username); Confirmation getConfirmationByUsernameAndEncounterId(@NonNull final String username,
                                                                final long encounterId); Confirmation addConfirmation(@NotNull final String username, final long encounterId); void deleteConfirmation(@NonNull final String username, final long confirmationId); boolean hasConfirmedEncounter(@NonNull final String username, final long encounterId); List<Confirmation> getConfirmations(final String type); }
ConfirmationService { public void deleteConfirmation(@NonNull final String username, final long confirmationId) { repository.delete(confirmationId); log.warn(SecurityMarkers.SECURITY_AUDIT, "User {} deleted confirmation {}", username, confirmationId); }  List<Confirmation> getConfirmationsByUsername(@NonNull final String username); Confirmation getConfirmationByUsernameAndEncounterId(@NonNull final String username,
                                                                final long encounterId); Confirmation addConfirmation(@NotNull final String username, final long encounterId); void deleteConfirmation(@NonNull final String username, final long confirmationId); boolean hasConfirmedEncounter(@NonNull final String username, final long encounterId); List<Confirmation> getConfirmations(final String type);  }