@Test public void findLatestByAppId() { List<EndpointProfileSchema> schemas = generateProfSchema(null, 4); Assert.assertEquals(4, schemas.size()); EndpointProfileSchema schema = schemas.get(0); Application app = schema.getApplication(); EndpointProfileSchema found = profileSchemaDao.findLatestByAppId(app.getId().toString()); Assert.assertNotNull(found); Assert.assertEquals(4, found.getVersion()); }
String id = profileSchemaDto.getId(); if (StringUtils.isBlank(id)) { EndpointProfileSchema endpointProfileSchema = profileSchemaDao.findLatestByAppId(appId); int version = -1; if (endpointProfileSchema != null) {