@Test
public void nsrManagementDeleteTest()
throws VimException, InterruptedException, ExecutionException, NamingException,
NotFoundException, WrongStatusException, PluginException, BadFormatException {
NetworkServiceRecord nsd_exp = createNetworkServiceRecord();
when(resourceManagement.release(any(VirtualDeploymentUnit.class), any(VNFCInstance.class)))
.thenReturn(new AsyncResult<Void>(null));
when(nsrRepository.findFirstByIdAndProjectId(nsd_exp.getId(), projectId)).thenReturn(nsd_exp);
Configuration system = new Configuration();
system.setConfigurationParameters(new HashSet<>());
ConfigurationParameter configurationParameter = new ConfigurationParameter();
configurationParameter.setConfKey("delete-on-all-status");
configurationParameter.setValue("true");
when(configurationManagement.queryByName("system")).thenReturn(system);
nsrManagement.delete(nsd_exp.getId(), projectId);
}
NetworkServiceRecordManagementClassSuiteTest.java 文件源码
java
阅读 20
收藏 0
点赞 0
评论 0
项目:NFVO
作者:
评论列表
文章目录