blob: 194086780c4258a939131965347bf641f27bd9d3 [file] [log] [blame]
package pta.de.resources;
import org.eclipse.jetty.http.HttpStatus;
import org.junit.Test;
import pta.de.core.controller.ServicesConfigCache;
import pta.de.core.exceptions.HttpStatusException;
import javax.ws.rs.core.Response;
import static junit.framework.TestCase.assertNotNull;
import static org.junit.Assert.assertEquals;
public class MicsCentralResourceTest {
@Test
public void testGetVersionInfo() {
Response r = new MicsCentralResource().getVersionInfo();
assertNotNull( r );
}
@Test
public void testGetServiceDistribution() throws HttpStatusException {
ServicesConfigCache.getInstance().readServerDistribution("servicesDistributionDevLocal.json");
Response r = new MicsCentralResource().getServiceDistribution("elogbook.openK" );
assertEquals( r.getStatus(), HttpStatus.OK_200 );
}
}