use of org.alfresco.rest.api.model.ModulePackage in project alfresco-remote-api by Alfresco.
the class ModulePackagesApiTest method testSingleModulePackage.
@Test
public void testSingleModulePackage() throws Exception {
setRequestContext(nonAdminUserName);
HttpResponse response = getSingle(MODULEPACKAGES, "NonSENSE_NOTFOUND", HttpStatus.SC_NOT_FOUND);
assertNotNull(response);
response = getSingle(MODULEPACKAGES, "alfresco-simple-module", HttpStatus.SC_OK);
assertNotNull(response);
ModulePackage simpleModule = parseRestApiEntry(response.getJsonResponse(), ModulePackage.class);
assertNotNull(simpleModule);
assertTrue("Simple module must be the correct version", "1.0.0-SNAPSHOT".equals(simpleModule.getVersion().toString()));
}
Aggregations