@Test public void testDeleteNotFound() { Mockito.when(crnService.getCurrentAccountId()).thenReturn(ACCOUNT_ID); NotFoundException ex = Assertions.assertThrows(NotFoundException.class, () -> { underTest.delete(ENVIRONMENT_ID); }); assertEquals("LdapConfig for environment 'environmentId' not found.", ex.getMessage()); }
public void delete(String environmentCrn) { String accountId = crnService.getCurrentAccountId(); delete(environmentCrn, accountId); }
LdapConfigService extends AbstractArchivistService<LdapConfig> { public void delete(String environmentCrn) { String accountId = crnService.getCurrentAccountId(); delete(environmentCrn, accountId); } }
LdapConfigService extends AbstractArchivistService<LdapConfig> { public void delete(String environmentCrn) { String accountId = crnService.getCurrentAccountId(); delete(environmentCrn, accountId); }  }
LdapConfigService extends AbstractArchivistService<LdapConfig> { public void delete(String environmentCrn) { String accountId = crnService.getCurrentAccountId(); delete(environmentCrn, accountId); }  LdapConfig createLdapConfig(LdapConfig ldapConfig); LdapConfig createLdapConfig(LdapConfig ldapConfig, String accountId); LdapConfig get(String environmentCrn); List<LdapConfig> findAllByEnvironmentAndAccountIdEvenIfArchived(String environmentCrn, String accountId); Optional<LdapConfig> find(String environmentCrn, String accountId, String clusterName); void delete(String environmentCrn); void delete(String environmentCrn, String accountId); void delete(String environmentCrn, String accountId, String clusterName); void deleteAllInEnvironment(String environmentCrn, String accountId); String testConnection(String environmentCrn, LdapConfig ldapConfig); @Override JpaRepository repository(); }
LdapConfigService extends AbstractArchivistService<LdapConfig> { public void delete(String environmentCrn) { String accountId = crnService.getCurrentAccountId(); delete(environmentCrn, accountId); }  LdapConfig createLdapConfig(LdapConfig ldapConfig); LdapConfig createLdapConfig(LdapConfig ldapConfig, String accountId); LdapConfig get(String environmentCrn); List<LdapConfig> findAllByEnvironmentAndAccountIdEvenIfArchived(String environmentCrn, String accountId); Optional<LdapConfig> find(String environmentCrn, String accountId, String clusterName); void delete(String environmentCrn); void delete(String environmentCrn, String accountId); void delete(String environmentCrn, String accountId, String clusterName); void deleteAllInEnvironment(String environmentCrn, String accountId); String testConnection(String environmentCrn, LdapConfig ldapConfig); @Override JpaRepository repository();  }