Code Review
/
vfc
/
nfvo
/
lcm.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
update grant vnf
[vfc/nfvo/lcm.git]
/
lcm
/
ns_vnfs
/
tests
/
tests.py
diff --git
a/lcm/ns_vnfs/tests/tests.py
b/lcm/ns_vnfs/tests/tests.py
index
2599749
..
e67c0d5
100644
(file)
--- a/
lcm/ns_vnfs/tests/tests.py
+++ b/
lcm/ns_vnfs/tests/tests.py
@@
-1013,7
+1013,14
@@
class TestGrantVnfViews(TestCase):
resp = GrantVnf(json.dumps(self.data)).exec_grant()
self.assertEqual(resp["vnfInstanceId"], "add_resources_but_no_off")
self.assertEqual(resp["vnfLcmOpOccId"], "vnf_lcm_op_occ_id")
resp = GrantVnf(json.dumps(self.data)).exec_grant()
self.assertEqual(resp["vnfInstanceId"], "add_resources_but_no_off")
self.assertEqual(resp["vnfLcmOpOccId"], "vnf_lcm_op_occ_id")
- vimConnections = []
+ vimConnections = [{
+ "id": "cloudOwner_casa",
+ "vimId": "cloudOwner_casa",
+ "vimType": None,
+ "interfaceInfo": None,
+ "accessInfo": {"tenant": "tenantA"},
+ "extra": None
+ }]
self.assertEqual(resp["vimConnections"], vimConnections)
@mock.patch.object(resmgr, "grant_vnf")
self.assertEqual(resp["vimConnections"], vimConnections)
@mock.patch.object(resmgr, "grant_vnf")
@@
-1106,7
+1113,14
@@
class TestGrantVnfViews(TestCase):
resp = GrantVnf(json.dumps(self.data)).exec_grant()
self.assertEqual(resp["vnfInstanceId"], "remove_resources_but_no_off")
self.assertEqual(resp["vnfLcmOpOccId"], "vnf_lcm_op_occ_id")
resp = GrantVnf(json.dumps(self.data)).exec_grant()
self.assertEqual(resp["vnfInstanceId"], "remove_resources_but_no_off")
self.assertEqual(resp["vnfLcmOpOccId"], "vnf_lcm_op_occ_id")
- vimConnections = []
+ vimConnections = [{
+ "id": "cloudOwner_casa",
+ "vimId": "cloudOwner_casa",
+ "vimType": None,
+ "interfaceInfo": None,
+ "accessInfo": {"tenant": "tenantA"},
+ "extra": None
+ }]
self.assertEqual(resp["vimConnections"], vimConnections)
@mock.patch.object(resmgr, "grant_vnf")
self.assertEqual(resp["vimConnections"], vimConnections)
@mock.patch.object(resmgr, "grant_vnf")