Package org.opennms.core.test.rest
Class AbstractSpringJerseyRestJsonTestCase
- java.lang.Object
-
- org.opennms.core.test.rest.AbstractSpringJerseyRestTestCase
-
- org.opennms.core.test.rest.AbstractSpringJerseyRestJsonTestCase
-
public abstract class AbstractSpringJerseyRestJsonTestCase extends AbstractSpringJerseyRestTestCase
- Author:
- Alejandro Galue
-
-
Field Summary
Fields Modifier and Type Field Description static String
ACCEPT
-
Fields inherited from class org.opennms.core.test.rest.AbstractSpringJerseyRestTestCase
contextPath, CXF_REST_V1_CONTEXT_PATH, CXF_REST_V2_CONTEXT_PATH, DELETE, GET, POST, PUT, servletContext, webApplicationContext
-
-
Constructor Summary
Constructors Constructor Description AbstractSpringJerseyRestJsonTestCase()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
createCategory()
protected void
createIpInterface()
protected void
createNode(int statusCode)
protected void
createService()
protected void
createSnmpInterface()
protected org.springframework.mock.web.MockHttpServletResponse
sendPost(String url, String xml, int statusCode, String expectedUrlSuffix)
protected String
sendRequest(org.springframework.mock.web.MockHttpServletRequest request, int expectedStatus, String expectedUrlSuffix)
-
Methods inherited from class org.opennms.core.test.rest.AbstractSpringJerseyRestTestCase
afterServletDestroy, afterServletStart, beforeServletDestroy, beforeServletStart, cleanUpImports, createNode, createRequest, createRequest, createRequest, createRequest, createResponse, dispatch, getContextListener, getDispatcher, getFilter, getJsonObject, getQueryString, getServletConfig, getUser, getUserRoles, getXmlObject, getXmlObject, parseParamData, putXmlObject, sendData, sendPost, sendPut, sendPut, sendRequest, sendRequest, sendRequest, sendRequest, setContextListener, setDispatcher, setFilter, setServletConfig, setUp, setUser, stringifyResponse, tearDown
-
-
-
-
Field Detail
-
ACCEPT
public static String ACCEPT
-
-
Method Detail
-
sendPost
protected org.springframework.mock.web.MockHttpServletResponse sendPost(String url, String xml, int statusCode, String expectedUrlSuffix) throws Exception
- Overrides:
sendPost
in classAbstractSpringJerseyRestTestCase
- Throws:
Exception
-
sendRequest
protected String sendRequest(org.springframework.mock.web.MockHttpServletRequest request, int expectedStatus, String expectedUrlSuffix) throws Exception, UnsupportedEncodingException
- Overrides:
sendRequest
in classAbstractSpringJerseyRestTestCase
- Throws:
Exception
UnsupportedEncodingException
-
createNode
protected void createNode(int statusCode) throws Exception
- Overrides:
createNode
in classAbstractSpringJerseyRestTestCase
- Throws:
Exception
-
createIpInterface
protected void createIpInterface() throws Exception
- Overrides:
createIpInterface
in classAbstractSpringJerseyRestTestCase
- Throws:
Exception
-
createSnmpInterface
protected void createSnmpInterface() throws Exception
- Overrides:
createSnmpInterface
in classAbstractSpringJerseyRestTestCase
- Throws:
Exception
-
createService
protected void createService() throws Exception
- Overrides:
createService
in classAbstractSpringJerseyRestTestCase
- Throws:
Exception
-
createCategory
protected void createCategory() throws Exception
- Overrides:
createCategory
in classAbstractSpringJerseyRestTestCase
- Throws:
Exception
-
-