@Test public final void testCreate() { List<CreateCloudInfraInfo> list = new ArrayList<CreateCloudInfraInfo>(); CreateCloudInfraInfo info = new CreateCloudInfraInfo(); info.setName("sd5"); info.setRegion("hef5"); info.setType("fusionmanager"); info.setVersion("1.5.0"); info.setIp("188.188.40.40"); info.setPort(8080); info.setUserName("fm01"); info.setPassword("Huawei@123"); info.setProtocol("https"); info.setDescription("Create"); info.setProvider("zxc"); info.setMetadata( new HashMap<String, String>() { private static final long serialVersionUID = -7209699276720391064L; { put("zxczxczxc", "zxczxcz"); } }); list.add(info); CreateCloudInfraReq req = new CreateCloudInfraReq(); req.setCloudInfra(list); CreateCloudInfraResp resp = service.create(req, "1"); System.err.println(g.toJson(resp)); }
@Test public final void testList() { ListCloudInfraReqEx reqEx = new ListCloudInfraReqEx(); reqEx.setVdcId("1"); reqEx.setStart(0); reqEx.setLimit(1); reqEx.setRange("0"); ListCloudInfraResp resp = service.list(reqEx); System.err.println(g.toJson(resp)); }