@MockPolicy(value=SharedSetUp.class) @PrepareForTest(value={LogUtils.class,AdminSvc.class,ExchangeAdapterFactory.class,Test2ExchangeAdapter.class,AdaptvAdapter.class}) @PowerMockIgnore(value={"javax.crypto.*","javax.management.*"}) public class AdminSvcSpec_debug1 extends Object
| Modifier and Type | Field and Description |
|---|---|
private javax.ws.rs.container.AsyncResponse |
asyncResponseMock |
private Ad |
debugAd |
private String |
debugAdId |
private Tag |
debugTag |
private String |
debugTagId |
private ServiceRunner |
serviceRunnerMock |
private javax.servlet.http.HttpServletRequest |
servletRequestMock |
private AdminSvc |
svc |
| Constructor and Description |
|---|
AdminSvcSpec_debug1() |
private ServiceRunner serviceRunnerMock
private javax.servlet.http.HttpServletRequest servletRequestMock
private javax.ws.rs.container.AsyncResponse asyncResponseMock
private AdminSvc svc
private Ad debugAd
private String debugAdId
private Tag debugTag
private String debugTagId
private void configMocks(String host, Ad[] allAds, String clickSimUrl) throws Exception
Exceptionpublic void negativeFlow_callsResumeWithInternalServerErrorIfGetAllReturnsNull()
throws Exception
Exceptionpublic void negativeFlow_callsResumeWithInternalServerErrorIfAdNotFound()
throws Exception
Exceptionpublic void negativeFlow_callsResumeWithInternalServerErrorIfGetTagsReturnsNull()
throws Exception
Exceptionpublic void negativeFlow_callsResumeWithInternalServerErrorIfTagNotFound()
throws Exception
Exceptionpublic void negativeFlow_callsResumeWithInternalServerErrorIfFindTagReturnsNull()
throws Exception
Exceptionpublic void negativeFlow_callsResumeWithInternalServerErrorIfExchangeAdapterNotFound()
throws Exception
Exceptionpublic void positiveFlow_callsResumeWithExpectedResponseIfAllDataAreCorrect()
throws Exception
Exceptionpublic void positiveFlow_callsResumeWithExpectedResponseIfClickSimUrlIsNotNull()
throws Exception
Exceptionpublic void positiveFlow_callsResumeWithExpectedResponseIfExchnageAdapterIsAdaptv()
throws Exception
Exceptionpublic void negativeFlow_callsResumeWithSeeOtherIfExchnageAdapterWithoutMacros()
throws Exception
Exceptionpublic void negativeFlow_callsResumeWithInternalServerErrorIfDebug2UrlIsBad()
throws Exception
Exceptionprivate void testDebug1(Ad[] allAds, List<Tag> tags, String exchangeName, String clickSimUrl, javax.ws.rs.core.Response.Status expectedResponseStatus) throws Exception
Exception