@Override public List<LogSchemaDto> getLogSchemasByApplicationId(String applicationId) throws ControlServiceException { return logSchemaService.findLogSchemasByAppId(applicationId); }
@Test public void removeLogSchemaByIdTest() { List<LogSchemaDto> schemas = logSchemaService.findLogSchemasByAppId(applicationDto.getId()); Assert.assertEquals(1, schemas.size()); logSchemaService.removeLogSchemaById(schemas.get(0).getId()); schemas = logSchemaService.findLogSchemasByAppId(applicationDto.getId()); Assert.assertEquals(0, schemas.size()); }
@Test public void removeLogSchemasByAppIdTest() { List<LogSchemaDto> schemas = logSchemaService.findLogSchemasByAppId(applicationDto.getId()); Assert.assertEquals(1, schemas.size()); logSchemaService.removeLogSchemasByAppId(applicationDto.getId()); schemas = logSchemaService.findLogSchemasByAppId(applicationDto.getId()); Assert.assertEquals(0, schemas.size()); }
@Test public void findLogSchemaByIdTest() { List<LogSchemaDto> schemas = logSchemaService.findLogSchemasByAppId(applicationDto.getId()); Assert.assertEquals(1, schemas.size()); LogSchemaDto dto = null; dto = logSchemaService.findLogSchemaById(schemas.get(0).getId()); Assert.assertNotNull(dto); }