本文整理汇总了Java中org.oscm.types.exceptions.TechnicalServiceOperationException类的典型用法代码示例。如果您正苦于以下问题:Java TechnicalServiceOperationException类的具体用法?Java TechnicalServiceOperationException怎么用?Java TechnicalServiceOperationException使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
TechnicalServiceOperationException类属于org.oscm.types.exceptions包,在下文中一共展示了TechnicalServiceOperationException类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: notifyAsyncSubscription_completion
import org.oscm.types.exceptions.TechnicalServiceOperationException; //导入依赖的package包/类
@Test
public void notifyAsyncSubscription_completion()
throws APPlatformException, BESNotificationException,
ObjectNotFoundException, SubscriptionStateException,
TechnicalServiceNotAliveException,
TechnicalServiceOperationException,
OrganizationAuthoritiesException, OperationNotPermittedException,
ValidationException {
// given
doReturn(subServ).when(besDAO).getBESWebService(
eq(SubscriptionService.class), any(ServiceInstance.class), any(Optional.class));
VOInstanceInfo info = new VOInstanceInfo();
doReturn(info).when(besDAO).getInstanceInfo(any(ServiceInstance.class),
any(InstanceResult.class));
ServiceInstance si = givenServiceInstance(false);
// when
besDAO.notifyAsyncSubscription(si, new InstanceResult(), true,
new APPlatformException(""));
// then
verify(subServ).completeAsyncSubscription(si.getSubscriptionId(),
si.getOrganizationId(), info);
}
示例2: notifyAsyncModifySubscription_completion
import org.oscm.types.exceptions.TechnicalServiceOperationException; //导入依赖的package包/类
@Test
public void notifyAsyncModifySubscription_completion()
throws APPlatformException, BESNotificationException,
ObjectNotFoundException, SubscriptionStateException,
TechnicalServiceNotAliveException,
TechnicalServiceOperationException,
OrganizationAuthoritiesException, OperationNotPermittedException {
// given
doReturn(subServ).when(besDAO).getBESWebService(
eq(SubscriptionService.class), any(ServiceInstance.class), any(Optional.class));
VOInstanceInfo info = new VOInstanceInfo();
doReturn(info).when(besDAO).getInstanceInfo(any(ServiceInstance.class),
any(InstanceResult.class));
ServiceInstance si = givenServiceInstance(false);
// when
besDAO.notifyAsyncModifySubscription(si, new InstanceResult(), true,
new APPlatformException(""));
// then
verify(subServ).completeAsyncModifySubscription(si.getSubscriptionId(),
si.getOrganizationId(), info);
}
示例3: notifyAsyncUpgradeSubscription_completion
import org.oscm.types.exceptions.TechnicalServiceOperationException; //导入依赖的package包/类
@Test
public void notifyAsyncUpgradeSubscription_completion()
throws APPlatformException, BESNotificationException,
ObjectNotFoundException, SubscriptionStateException,
TechnicalServiceNotAliveException,
TechnicalServiceOperationException,
OrganizationAuthoritiesException, OperationNotPermittedException {
// given
doReturn(subServ).when(besDAO).getBESWebService(
eq(SubscriptionService.class), any(ServiceInstance.class), any(Optional.class));
VOInstanceInfo info = new VOInstanceInfo();
doReturn(info).when(besDAO).getInstanceInfo(any(ServiceInstance.class),
any(InstanceResult.class));
ServiceInstance si = givenServiceInstance(false);
// when
besDAO.notifyAsyncUpgradeSubscription(si, new InstanceResult(), true,
new APPlatformException(""));
// then
verify(subServ).completeAsyncUpgradeSubscription(
si.getSubscriptionId(), si.getOrganizationId(), info);
}
示例4: notifyAsyncSubscription_completion_OperationNotPermited
import org.oscm.types.exceptions.TechnicalServiceOperationException; //导入依赖的package包/类
@Test(expected = BESNotificationException.class)
public void notifyAsyncSubscription_completion_OperationNotPermited()
throws APPlatformException, BESNotificationException,
ObjectNotFoundException, SubscriptionStateException,
TechnicalServiceNotAliveException,
TechnicalServiceOperationException,
OrganizationAuthoritiesException, OperationNotPermittedException,
ValidationException {
// given
doReturn(subServ).when(besDAO).getBESWebService(
eq(SubscriptionService.class), any(ServiceInstance.class), any(Optional.class));
doReturn(new VOInstanceInfo()).when(besDAO).getInstanceInfo(
any(ServiceInstance.class), any(InstanceResult.class));
ServiceInstance si = givenServiceInstance(false);
doThrow(new OperationNotPermittedException()).when(subServ)
.completeAsyncSubscription(anyString(), anyString(),
any(VOInstanceInfo.class));
// when
besDAO.notifyAsyncSubscription(si, new InstanceResult(), true,
new APPlatformException(""));
}
示例5: notifyAsyncModifySubscription_completion_OperationNotPermited
import org.oscm.types.exceptions.TechnicalServiceOperationException; //导入依赖的package包/类
@Test(expected = BESNotificationException.class)
public void notifyAsyncModifySubscription_completion_OperationNotPermited()
throws APPlatformException, BESNotificationException,
ObjectNotFoundException, SubscriptionStateException,
TechnicalServiceNotAliveException,
TechnicalServiceOperationException,
OrganizationAuthoritiesException, OperationNotPermittedException {
// given
doReturn(subServ).when(besDAO).getBESWebService(
eq(SubscriptionService.class), any(ServiceInstance.class), any(Optional.class));
doReturn(new VOInstanceInfo()).when(besDAO).getInstanceInfo(
any(ServiceInstance.class), any(InstanceResult.class));
ServiceInstance si = givenServiceInstance(false);
doThrow(new OperationNotPermittedException()).when(subServ)
.completeAsyncModifySubscription(anyString(), anyString(),
any(VOInstanceInfo.class));
// when
besDAO.notifyAsyncModifySubscription(si, new InstanceResult(), true,
new APPlatformException(""));
}
示例6: notifyAsyncUpgradeSubscription_completion_OperationNotPermited
import org.oscm.types.exceptions.TechnicalServiceOperationException; //导入依赖的package包/类
@Test(expected = BESNotificationException.class)
public void notifyAsyncUpgradeSubscription_completion_OperationNotPermited()
throws APPlatformException, BESNotificationException,
ObjectNotFoundException, SubscriptionStateException,
TechnicalServiceNotAliveException,
TechnicalServiceOperationException,
OrganizationAuthoritiesException, OperationNotPermittedException {
// given
doReturn(subServ).when(besDAO).getBESWebService(
eq(SubscriptionService.class), any(ServiceInstance.class), any(Optional.class));
doReturn(new VOInstanceInfo()).when(besDAO).getInstanceInfo(
any(ServiceInstance.class), any(InstanceResult.class));
ServiceInstance si = givenServiceInstance(false);
doThrow(new OperationNotPermittedException()).when(subServ)
.completeAsyncUpgradeSubscription(anyString(), anyString(),
any(VOInstanceInfo.class));
// when
besDAO.notifyAsyncUpgradeSubscription(si, new InstanceResult(), true,
new APPlatformException(""));
}
示例7: notifyAsyncSubscription_completion_ObjectNotFound
import org.oscm.types.exceptions.TechnicalServiceOperationException; //导入依赖的package包/类
@Test
public void notifyAsyncSubscription_completion_ObjectNotFound()
throws APPlatformException, BESNotificationException,
ObjectNotFoundException, SubscriptionStateException,
TechnicalServiceNotAliveException,
TechnicalServiceOperationException,
OrganizationAuthoritiesException, OperationNotPermittedException,
ValidationException {
// given
doReturn(subServ).when(besDAO).getBESWebService(
eq(SubscriptionService.class), any(ServiceInstance.class), any(Optional.class));
doReturn(new VOInstanceInfo()).when(besDAO).getInstanceInfo(
any(ServiceInstance.class), any(InstanceResult.class));
ServiceInstance si = givenServiceInstance(false);
doThrow(new ObjectNotFoundException()).when(subServ)
.completeAsyncSubscription(anyString(), anyString(),
any(VOInstanceInfo.class));
// when
besDAO.notifyAsyncSubscription(si, new InstanceResult(), true,
new APPlatformException(""));
// then no exception
}
示例8: notifyAsyncModifySubscription_completion_ObjectNotFound
import org.oscm.types.exceptions.TechnicalServiceOperationException; //导入依赖的package包/类
@Test
public void notifyAsyncModifySubscription_completion_ObjectNotFound()
throws APPlatformException, BESNotificationException,
ObjectNotFoundException, SubscriptionStateException,
TechnicalServiceNotAliveException,
TechnicalServiceOperationException,
OrganizationAuthoritiesException, OperationNotPermittedException {
// given
doReturn(subServ).when(besDAO).getBESWebService(
eq(SubscriptionService.class), any(ServiceInstance.class), any(Optional.class));
doReturn(new VOInstanceInfo()).when(besDAO).getInstanceInfo(
any(ServiceInstance.class), any(InstanceResult.class));
ServiceInstance si = givenServiceInstance(false);
doThrow(new ObjectNotFoundException()).when(subServ)
.completeAsyncModifySubscription(anyString(), anyString(),
any(VOInstanceInfo.class));
// when
besDAO.notifyAsyncModifySubscription(si, new InstanceResult(), true,
new APPlatformException(""));
// then no exception
}
示例9: notifyAsyncUpgradeSubscription_completion_ObjectNotFound
import org.oscm.types.exceptions.TechnicalServiceOperationException; //导入依赖的package包/类
@Test
public void notifyAsyncUpgradeSubscription_completion_ObjectNotFound()
throws APPlatformException, BESNotificationException,
ObjectNotFoundException, SubscriptionStateException,
TechnicalServiceNotAliveException,
TechnicalServiceOperationException,
OrganizationAuthoritiesException, OperationNotPermittedException {
// given
doReturn(subServ).when(besDAO).getBESWebService(
eq(SubscriptionService.class), any(ServiceInstance.class), any(Optional.class));
doReturn(new VOInstanceInfo()).when(besDAO).getInstanceInfo(
any(ServiceInstance.class), any(InstanceResult.class));
ServiceInstance si = givenServiceInstance(false);
doThrow(new ObjectNotFoundException()).when(subServ)
.completeAsyncUpgradeSubscription(anyString(), anyString(),
any(VOInstanceInfo.class));
// when
besDAO.notifyAsyncUpgradeSubscription(si, new InstanceResult(), true,
new APPlatformException(""));
// then no exception
}
示例10: notifyAsyncModifySubscription_completion_SubscriptionState
import org.oscm.types.exceptions.TechnicalServiceOperationException; //导入依赖的package包/类
@Test
public void notifyAsyncModifySubscription_completion_SubscriptionState()
throws APPlatformException, BESNotificationException,
ObjectNotFoundException, SubscriptionStateException,
TechnicalServiceNotAliveException,
TechnicalServiceOperationException,
OrganizationAuthoritiesException, OperationNotPermittedException {
// given
doReturn(subServ).when(besDAO).getBESWebService(
eq(SubscriptionService.class), any(ServiceInstance.class), any(Optional.class));
doReturn(new VOInstanceInfo()).when(besDAO).getInstanceInfo(
any(ServiceInstance.class), any(InstanceResult.class));
ServiceInstance si = givenServiceInstance(false);
doThrow(new SubscriptionStateException()).when(subServ)
.completeAsyncModifySubscription(anyString(), anyString(),
any(VOInstanceInfo.class));
doNothing().when(besDAO).handleSubscriptionStateException(
any(ServiceInstance.class), any(InstanceResult.class),
eq(true), any(SubscriptionStateException.class));
// when
besDAO.notifyAsyncModifySubscription(si, new InstanceResult(), true,
new APPlatformException(""));
// then no exception
}
示例11: notifyAsyncUpgradeSubscription_completion_SubscriptionState
import org.oscm.types.exceptions.TechnicalServiceOperationException; //导入依赖的package包/类
@Test
public void notifyAsyncUpgradeSubscription_completion_SubscriptionState()
throws APPlatformException, BESNotificationException,
ObjectNotFoundException, SubscriptionStateException,
TechnicalServiceNotAliveException,
TechnicalServiceOperationException,
OrganizationAuthoritiesException, OperationNotPermittedException {
// given
doReturn(subServ).when(besDAO).getBESWebService(
eq(SubscriptionService.class), any(ServiceInstance.class), any(Optional.class));
doReturn(new VOInstanceInfo()).when(besDAO).getInstanceInfo(
any(ServiceInstance.class), any(InstanceResult.class));
ServiceInstance si = givenServiceInstance(false);
doThrow(new SubscriptionStateException()).when(subServ)
.completeAsyncUpgradeSubscription(anyString(), anyString(),
any(VOInstanceInfo.class));
doNothing().when(besDAO).handleSubscriptionStateException(
any(ServiceInstance.class), any(InstanceResult.class),
eq(true), any(SubscriptionStateException.class));
// when
besDAO.notifyAsyncUpgradeSubscription(si, new InstanceResult(), true,
new APPlatformException(""));
// then no exception
}
示例12: terminateSubscription_successful
import org.oscm.types.exceptions.TechnicalServiceOperationException; //导入依赖的package包/类
@Test
public void terminateSubscription_successful() throws APPlatformException,
ObjectNotFoundException, OperationNotPermittedException,
OrganizationAuthoritiesException,
TechnicalServiceNotAliveException,
TechnicalServiceOperationException,
ConcurrentModificationException, SubscriptionStateException,
BESNotificationException {
// given
doReturn(subServ).when(besDAO).getBESWebService(
eq(SubscriptionService.class), any(ServiceInstance.class), any(Optional.class));
ServiceInstance si = givenServiceInstance(false);
String locale = "en";
// when
besDAO.terminateSubscription(si, locale);
// then
verify(subServ, times(1)).getSubscriptionForCustomer(
si.getOrganizationId(), si.getSubscriptionId());
verify(subServ, times(1)).terminateSubscription(
any(VOSubscription.class), anyString());
}
示例13: subscribe
import org.oscm.types.exceptions.TechnicalServiceOperationException; //导入依赖的package包/类
private VOSubscription subscribe() throws ObjectNotFoundException,
NonUniqueBusinessKeyException, ValidationException,
PaymentInformationException, ServiceParameterException,
ServiceChangedException, PriceModelException,
TechnicalServiceNotAliveException,
TechnicalServiceOperationException, OperationNotPermittedException,
SubscriptionAlreadyExistsException, OperationPendingException,
MandatoryUdaMissingException, ConcurrentModificationException,
SubscriptionStateException {
createdSubscription = createSubscription();
createdSubscription = subscrServiceForCustomer.subscribeToService(
createdSubscription, freeService, usageLicences, null, null,
new ArrayList<VOUda>());
subscriptionID = createdSubscription.getSubscriptionId();
return createdSubscription;
}
示例14: notifyAsyncSubscription_completion
import org.oscm.types.exceptions.TechnicalServiceOperationException; //导入依赖的package包/类
@Test
public void notifyAsyncSubscription_completion()
throws APPlatformException, BESNotificationException,
ObjectNotFoundException, SubscriptionStateException,
TechnicalServiceNotAliveException,
TechnicalServiceOperationException,
OrganizationAuthoritiesException, OperationNotPermittedException,
ValidationException {
// given
doReturn(subServ).when(besDAO).getBESWebService(
eq(SubscriptionService.class), any(ServiceInstance.class));
VOInstanceInfo info = new VOInstanceInfo();
doReturn(info).when(besDAO).getInstanceInfo(any(ServiceInstance.class),
any(InstanceResult.class));
ServiceInstance si = givenServiceInstance(false);
// when
besDAO.notifyAsyncSubscription(si, new InstanceResult(), true,
new APPlatformException(""));
// then
verify(subServ).completeAsyncSubscription(si.getSubscriptionId(),
si.getOrganizationId(), info);
}
示例15: notifyAsyncModifySubscription_completion
import org.oscm.types.exceptions.TechnicalServiceOperationException; //导入依赖的package包/类
@Test
public void notifyAsyncModifySubscription_completion()
throws APPlatformException, BESNotificationException,
ObjectNotFoundException, SubscriptionStateException,
TechnicalServiceNotAliveException,
TechnicalServiceOperationException,
OrganizationAuthoritiesException, OperationNotPermittedException {
// given
doReturn(subServ).when(besDAO).getBESWebService(
eq(SubscriptionService.class), any(ServiceInstance.class));
VOInstanceInfo info = new VOInstanceInfo();
doReturn(info).when(besDAO).getInstanceInfo(any(ServiceInstance.class),
any(InstanceResult.class));
ServiceInstance si = givenServiceInstance(false);
// when
besDAO.notifyAsyncModifySubscription(si, new InstanceResult(), true,
new APPlatformException(""));
// then
verify(subServ).completeAsyncModifySubscription(si.getSubscriptionId(),
si.getOrganizationId(), info);
}