1 # Copyright 2016-2017 ZTE Corporation.
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
7 # http://www.apache.org/licenses/LICENSE-2.0
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
18 from django.test import TestCase, Client
19 from rest_framework import status
21 from lcm.pub.database.models import NfInstModel, JobModel, NSInstModel, VmInstModel
22 from lcm.pub.exceptions import NSLCMException
23 from lcm.pub.utils import restcall
24 from lcm.pub.utils.jobutil import JOB_MODEL_STATUS
25 from lcm.pub.utils.jobutil import JobUtil, JOB_TYPE
26 from lcm.pub.utils.timeutil import now_time
27 from lcm.pub.utils.values import ignore_case_get
28 from lcm.ns_vnfs.biz.create_vnfs import CreateVnfs
29 from lcm.ns_vnfs.biz.heal_vnfs import NFHealService
30 from lcm.ns_vnfs.biz.scale_vnfs import NFManualScaleService
31 from lcm.ns_vnfs.biz.terminate_nfs import TerminateVnfs
32 from lcm.ns_vnfs.const import VNF_STATUS, INST_TYPE
33 from lcm.ns_vnfs.biz import create_vnfs
36 class TestGetVnfViews(TestCase):
38 self.client = Client()
39 self.nf_inst_id = str(uuid.uuid4())
40 NfInstModel(nfinstid=self.nf_inst_id, nf_name='vnf1', vnfm_inst_id='1', vnf_id='vnf_id1',
41 status=VNF_STATUS.ACTIVE, create_time=now_time(), lastuptime=now_time()).save()
44 NfInstModel.objects.all().delete()
46 def test_get_vnf(self):
47 response = self.client.get("/api/nslcm/v1/ns/vnfs/%s" % self.nf_inst_id)
48 self.failUnlessEqual(status.HTTP_200_OK, response.status_code)
49 context = json.loads(response.content)
50 self.failUnlessEqual(self.nf_inst_id, context['vnfInstId'])
53 class TestCreateVnfViews(TestCase):
55 self.ns_inst_id = str(uuid.uuid4())
56 self.job_id = str(uuid.uuid4())
58 "nsInstanceId": self.ns_inst_id,
59 "additionalParamForNs": {
60 "inputs": json.dumps({
64 "additionalParamForVnf": [
66 "vnfprofileid": "VBras",
68 "inputs": json.dumps({
72 "vnfminstanceid": "1",
79 self.client = Client()
80 NSInstModel(id=self.ns_inst_id, name='ns', nspackage_id='1', nsd_id='nsd_id', description='description',
81 status='instantiating', nsd_model=json.dumps(nsd_model_dict), create_time=now_time(),
82 lastuptime=now_time()).save()
85 NfInstModel.objects.all().delete()
86 JobModel.objects.all().delete()
88 @mock.patch.object(CreateVnfs, 'run')
89 def test_create_vnf(self, mock_run):
90 response = self.client.post("/api/nslcm/v1/ns/vnfs", data=self.data)
91 self.failUnlessEqual(status.HTTP_202_ACCEPTED, response.status_code)
92 context = json.loads(response.content)
93 self.assertTrue(NfInstModel.objects.filter(nfinstid=context['vnfInstId']).exists())
95 @mock.patch.object(restcall, 'call_req')
96 def test_create_vnf_thread(self, mock_call_req):
97 nf_inst_id, job_id = create_vnfs.prepare_create_params()
99 "/api/ztevnfmdriver/v1/1/vnfs":
100 [0, json.JSONEncoder().encode({"jobId": self.job_id, "vnfInstanceId": 3}), '200'],
101 "/api/catalog/v1/vnfpackages/zte_vbras":
102 [0, json.JSONEncoder().encode(nf_package_info), '200'],
103 "/external-system/esr-vnfm-list/esr-vnfm/1?depth=all":
104 [0, json.JSONEncoder().encode(vnfm_info), '200'],
105 "/api/resmgr/v1/vnf":
106 [0, json.JSONEncoder().encode({}), '200'],
107 "/api/resmgr/v1/vnfinfo":
108 [0, json.JSONEncoder().encode({}), '200'],
109 "/network/generic-vnfs/generic-vnf/%s" % nf_inst_id:
110 [0, json.JSONEncoder().encode({}), '201'],
111 "/cloud-infrastructure/cloud-regions/cloud-region/zte/test?depth=all":
112 [0, json.JSONEncoder().encode(vim_info), '201'],
113 "/cloud-infrastructure/cloud-regions/cloud-region/zte/test/tenants/tenant/admin/vservers/vserver/1":
114 [0, json.JSONEncoder().encode({}), '201'],
115 "/api/ztevnfmdriver/v1/1/jobs/" + self.job_id + "?responseId=0":
116 [0, json.JSONEncoder().encode({"jobid": self.job_id,
117 "responsedescriptor": {"progress": "100",
118 "status": JOB_MODEL_STATUS.FINISHED,
120 "statusdescription": "creating",
122 "responsehistorylist": [
124 "status": JOB_MODEL_STATUS.PROCESSING,
126 "statusdescription": "creating",
127 "errorcode": "0"}]}}), '200']}
129 def side_effect(*args):
130 return mock_vals[args[4]]
131 mock_call_req.side_effect = side_effect
133 'ns_instance_id': ignore_case_get(self.data, 'nsInstanceId'),
134 'additional_param_for_ns': ignore_case_get(self.data, 'additionalParamForNs'),
135 'additional_param_for_vnf': ignore_case_get(self.data, 'additionalParamForVnf'),
136 'vnf_index': ignore_case_get(self.data, 'vnfIndex')
138 CreateVnfs(data, nf_inst_id, job_id).run()
139 self.assertTrue(NfInstModel.objects.get(nfinstid=nf_inst_id).status, VNF_STATUS.ACTIVE)
142 class TestTerminateVnfViews(TestCase):
144 self.client = Client()
145 self.ns_inst_id = str(uuid.uuid4())
146 self.nf_inst_id = '1'
147 self.vnffg_id = str(uuid.uuid4())
148 self.vim_id = str(uuid.uuid4())
149 self.job_id = str(uuid.uuid4())
151 self.tenant = "tenantname"
155 "vnfdName": "PGW001",
156 "vnfProvider": "zte",
157 "vnfdVersion": "V00001",
158 "vnfVersion": "V5.10.20",
161 "description": "PGW VNFD description",
163 "vnfExtendType": "driver"
166 NSInstModel.objects.all().delete()
167 NfInstModel.objects.all().delete()
168 VmInstModel.objects.all().delete()
169 NSInstModel(id=self.ns_inst_id, name="ns_name").save()
170 NfInstModel.objects.create(nfinstid=self.nf_inst_id,
174 ns_inst_id='111,2-2-2',
181 mnfinstid=self.nf_uuid,
183 vnfd_model=self.vnfd_model)
184 VmInstModel.objects.create(vmid="1",
187 insttype=INST_TYPE.VNF,
188 instid=self.nf_inst_id,
193 NSInstModel.objects.all().delete()
194 NfInstModel.objects.all().delete()
196 @mock.patch.object(TerminateVnfs, 'run')
197 def test_terminate_vnf_url(self, mock_run):
199 "terminationType": "forceful",
200 "gracefulTerminationTimeout": "600"}
202 response = self.client.post("/api/nslcm/v1/ns/vnfs/%s" % self.nf_inst_id, data=req_data)
203 self.failUnlessEqual(status.HTTP_201_CREATED, response.status_code)
205 @mock.patch.object(restcall, 'call_req')
206 def test_terminate_vnf(self, mock_call_req):
207 job_id = JobUtil.create_job("VNF", JOB_TYPE.TERMINATE_VNF, self.nf_inst_id)
209 nfinst = NfInstModel.objects.filter(nfinstid=self.nf_inst_id)
211 self.failUnlessEqual(1, 1)
213 self.failUnlessEqual(1, 0)
216 "vnf-id": "vnf-id-test111",
217 "vnf-name": "vnf-name-test111",
218 "vnf-type": "vnf-type-test111",
220 "is-closed-loop-disabled": False,
221 "resource-version": "1505465356262"
225 "responsedescriptor": {
227 "status": JOB_MODEL_STATUS.FINISHED,
229 "statusdescription": "creating",
231 "responsehistorylist": [
234 "status": JOB_MODEL_STATUS.PROCESSING,
236 "statusdescription": "creating",
244 "/external-system/esr-vnfm-list/esr-vnfm/1?depth=all":
245 [0, json.JSONEncoder().encode(vnfm_info), '200'],
246 "/api/ztevnfmdriver/v1/1/vnfs/111/terminate":
247 [0, json.JSONEncoder().encode({"jobId": job_id}), '200'],
248 "/api/resmgr/v1/vnf/1":
249 [0, json.JSONEncoder().encode({"jobId": job_id}), '200'],
250 "/cloud-infrastructure/cloud-regions/cloud-region/zte/test?depth=all":
251 [0, json.JSONEncoder().encode(vim_info), '201'],
252 "/cloud-infrastructure/cloud-regions/cloud-region/zte/test/tenants/tenant/admin/vservers/vserver/1?depth=all":
253 [0, json.JSONEncoder().encode(vserver_info), '201'],
254 "/cloud-infrastructure/cloud-regions/cloud-region/zte/test/tenants/tenant/admin/vservers/vserver/1?resource-version=1505465356263":
255 [0, json.JSONEncoder().encode({}), '200'],
256 "/api/ztevnfmdriver/v1/1/jobs/" + job_id + "?responseId=0":
257 [0, json.JSONEncoder().encode(job_info), '200'],
258 "/network/generic-vnfs/generic-vnf/1?depth=all":
259 [0, json.JSONEncoder().encode(vnf_info), '200'],
260 "/network/generic-vnfs/generic-vnf/1?resource-version=1505465356262":
261 [0, json.JSONEncoder().encode({}), '200']
264 def side_effect(*args):
265 return mock_vals[args[4]]
266 mock_call_req.side_effect = side_effect
269 "terminationType": "forceful",
270 "gracefulTerminationTimeout": "600"
273 TerminateVnfs(req_data, self.nf_inst_id, job_id).run()
274 nfinst = NfInstModel.objects.filter(nfinstid=self.nf_inst_id)
276 self.failUnlessEqual(1, 0)
278 self.failUnlessEqual(1, 1)
281 class TestScaleVnfViews(TestCase):
283 self.client = Client()
284 self.ns_inst_id = str(uuid.uuid4())
285 self.nf_inst_id = str(uuid.uuid4())
286 self.vnffg_id = str(uuid.uuid4())
287 self.vim_id = str(uuid.uuid4())
288 self.job_id = str(uuid.uuid4())
290 self.tenant = "tenantname"
291 NSInstModel(id=self.ns_inst_id, name="ns_name").save()
292 NfInstModel.objects.create(nfinstid=self.nf_inst_id, nf_name='name_1', vnf_id='1',
293 vnfm_inst_id='1', ns_inst_id='111,2-2-2',
294 max_cpu='14', max_ram='12296', max_hd='101', max_shd="20", max_net=10,
295 status='active', mnfinstid=self.nf_uuid, package_id='pkg1',
296 vnfd_model='{"metadata": {"vnfdId": "1","vnfdName": "PGW001",'
297 '"vnfProvider": "zte","vnfdVersion": "V00001","vnfVersion": "V5.10.20",'
298 '"productType": "CN","vnfType": "PGW",'
299 '"description": "PGW VNFD description",'
300 '"isShared":true,"vnfExtendType":"driver"}}')
303 NSInstModel.objects.all().delete()
304 NfInstModel.objects.all().delete()
306 def test_scale_vnf(self):
309 "flavour_id": "flavour1",
314 "instances_minimum_number": 1,
315 "instances_maximum_number": 4,
316 "local_affinity_antiaffinity_rule": [
318 "affinity_antiaffinity": "affinity",
327 "name": "demo_aspect",
328 "description": "demo_aspect",
329 "associated_group": "elementGroup1",
335 "group_id": "elementGroup1",
338 "name": "elementGroup1",
340 "members": ["gsu_vm", "pfu_vm"]
348 "aspectId": "demo_aspect1",
350 "additionalParam": vnfd_info
354 "aspectId": "demo_aspect2",
356 "additionalParam": vnfd_info
361 NFManualScaleService(self.nf_inst_id, req_data).run()
362 nsIns = NfInstModel.objects.filter(nfinstid=self.nf_inst_id)
363 self.assertIsNotNone(nsIns)
365 @mock.patch.object(NFManualScaleService, "send_nf_scaling_request")
366 def test_scale_vnf_success(self, mock_send_nf_scaling_request):
369 "flavour_id": "flavour1",
374 "instances_minimum_number": 1,
375 "instances_maximum_number": 4,
376 "local_affinity_antiaffinity_rule": [
378 "affinity_antiaffinity": "affinity",
387 "name": "demo_aspect",
388 "description": "demo_aspect",
389 "associated_group": "elementGroup1",
395 "group_id": "elementGroup1",
398 "name": "elementGroup1",
400 "members": ["gsu_vm", "pfu_vm"]
408 "aspectId": "demo_aspect1",
410 "additionalParam": vnfd_info
414 "aspectId": "demo_aspect2",
416 "additionalParam": vnfd_info
420 scale_service = NFManualScaleService(self.nf_inst_id, req_data)
422 nsIns = NfInstModel.objects.filter(nfinstid=self.nf_inst_id)
423 self.assertIsNotNone(nsIns)
425 jobs = JobModel.objects.filter(jobid=scale_service.job_id)
426 self.assertIsNotNone(100, jobs[0].progress)
429 class TestHealVnfViews(TestCase):
431 self.client = Client()
432 self.ns_inst_id = str(uuid.uuid4())
433 self.nf_inst_id = str(uuid.uuid4())
436 self.job_id = JobUtil.create_job("VNF", JOB_TYPE.HEAL_VNF, self.nf_inst_id)
438 NSInstModel(id=self.ns_inst_id, name="ns_name").save()
439 NfInstModel.objects.create(nfinstid=self.nf_inst_id,
443 ns_inst_id='111,2-2-2',
450 mnfinstid=self.nf_uuid,
452 vnfd_model=json.dumps({
455 "vnfdName": "PGW001",
456 "vnfProvider": "zte",
457 "vnfdVersion": "V00001",
458 "vnfVersion": "V5.10.20",
461 "description": "PGW VNFD description",
463 "vnfExtendType": "driver"
468 NSInstModel.objects.all().delete()
469 NfInstModel.objects.all().delete()
471 @mock.patch.object(restcall, "call_req")
472 def test_heal_vnf(self, mock_call_req):
475 "/api/ztevnfmdriver/v1/1/vnfs/111/heal":
476 [0, json.JSONEncoder().encode({"jobId": self.job_id}), '200'],
477 "/external-system/esr-vnfm-list/esr-vnfm/1":
478 [0, json.JSONEncoder().encode(vnfm_info), '200'],
479 "/api/resmgr/v1/vnf/1":
480 [0, json.JSONEncoder().encode({"jobId": self.job_id}), '200'],
481 "/api/ztevnfmdriver/v1/1/jobs/" + self.job_id + "?responseId=0":
482 [0, json.JSONEncoder().encode({
483 "jobId": self.job_id,
484 "responsedescriptor": {
486 "status": JOB_MODEL_STATUS.FINISHED,
488 "statusdescription": "creating",
490 "responsehistorylist": [{
492 "status": JOB_MODEL_STATUS.PROCESSING,
494 "statusdescription": "creating",
500 def side_effect(*args):
501 return mock_vals[args[4]]
503 mock_call_req.side_effect = side_effect
514 NFHealService(self.nf_inst_id, req_data).run()
516 self.assertEqual(NfInstModel.objects.get(nfinstid=self.nf_inst_id).status, VNF_STATUS.ACTIVE)
518 @mock.patch.object(NFHealService, "run")
519 def test_heal_vnf_non_existing_vnf(self, mock_biz):
520 mock_biz.side_effect = NSLCMException("VNF Not Found")
533 self.assertRaises(NSLCMException, NFHealService(nf_inst_id, req_data).run)
534 self.assertEqual(len(NfInstModel.objects.filter(nfinstid=nf_inst_id)), 0)
537 class TestGetVnfmInfoViews(TestCase):
539 self.client = Client()
540 self.vnfm_id = str(uuid.uuid4())
545 @mock.patch.object(restcall, "call_req")
546 def test_get_vnfm_info(self, mock_call_req):
548 "vnfm-id": "example-vnfm-id-val-62576",
549 "vim-id": "example-vim-id-val-35114",
550 "certificate-url": "example-certificate-url-val-90242",
551 "esr-system-info-list": {
554 "esr-system-info-id": "example-esr-system-info-id-val-78484",
555 "system-name": "example-system-name-val-23790",
556 "type": "example-type-val-52596",
557 "vendor": "example-vendor-val-47399",
558 "version": "example-version-val-42051",
559 "service-url": "example-service-url-val-10731",
560 "user-name": "example-user-name-val-65946",
561 "password": "example-password-val-22505",
562 "system-type": "example-system-type-val-27221",
563 "protocal": "example-protocal-val-54632",
564 "ssl-cacert": "example-ssl-cacert-val-45965",
565 "ssl-insecure": True,
566 "ip-address": "example-ip-address-val-19212",
567 "port": "example-port-val-57641",
568 "cloud-domain": "example-cloud-domain-val-26296",
569 "default-tenant": "example-default-tenant-val-87724"
574 r1 = [0, json.JSONEncoder().encode(vnfm_info_aai), '200']
575 mock_call_req.side_effect = [r1]
576 esr_system_info = ignore_case_get(ignore_case_get(vnfm_info_aai, "esr-system-info-list"), "esr-system-info")
578 "vnfmId": vnfm_info_aai["vnfm-id"],
579 "name": vnfm_info_aai["vnfm-id"],
580 "type": ignore_case_get(esr_system_info[0], "type"),
581 "vimId": vnfm_info_aai["vim-id"],
582 "vendor": ignore_case_get(esr_system_info[0], "vendor"),
583 "version": ignore_case_get(esr_system_info[0], "version"),
584 "description": "vnfm",
585 "certificateUrl": vnfm_info_aai["certificate-url"],
586 "url": ignore_case_get(esr_system_info[0], "service-url"),
587 "userName": ignore_case_get(esr_system_info[0], "user-name"),
588 "password": ignore_case_get(esr_system_info[0], "password"),
592 response = self.client.get("/api/nslcm/v1/vnfms/%s" % self.vnfm_id)
593 self.failUnlessEqual(status.HTTP_200_OK, response.status_code, response.content)
594 context = json.loads(response.content)
595 self.assertEqual(expect_data, context)
598 class TestGetVimInfoViews(TestCase):
600 self.client = Client()
601 self.vim_id = "zte_test"
606 @mock.patch.object(restcall, "call_req")
607 def test_get_vim_info(self, mock_call_req):
608 r1 = [0, json.JSONEncoder().encode(vim_info), '200']
609 mock_call_req.side_effect = [r1]
610 esr_system_info = ignore_case_get(ignore_case_get(vim_info, "esr-system-info-list"), "esr-system-info")
612 "vimId": self.vim_id,
614 "url": ignore_case_get(esr_system_info[0], "service-url"),
615 "userName": ignore_case_get(esr_system_info[0], "user-name"),
616 "password": ignore_case_get(esr_system_info[0], "password"),
617 # "tenant": ignore_case_get(tenants[0], "tenant-id"),
618 "tenant": ignore_case_get(esr_system_info[0], "default-tenant"),
619 "vendor": ignore_case_get(esr_system_info[0], "vendor"),
620 "version": ignore_case_get(esr_system_info[0], "version"),
621 "description": "vim",
623 "type": ignore_case_get(esr_system_info[0], "type"),
627 response = self.client.get("/api/nslcm/v1/vims/%s" % self.vim_id)
628 self.failUnlessEqual(status.HTTP_200_OK, response.status_code)
629 context = json.loads(response.content)
630 self.assertEqual(expect_data["url"], context["url"])
634 'local_storages': [],
647 'vdu_id': u'vdu_omm.001',
648 'image_file': u'opencos_sss_omm_img_release_20150723-1-disk1',
660 'support_scaling': False,
663 'storage_policy': '',
666 'availability_zone': '',
672 'inject_data_list': [
679 'local_affinity_antiaffinity_rule': {
682 'template_id': u'omm.001',
683 'manual_scale_select_vim': False
685 'description': u'singleommvm'
699 'image_file': u'sss',
711 'support_scaling': False,
714 'storage_policy': '',
717 'availability_zone': '',
723 'inject_data_list': [
730 'local_affinity_antiaffinity_rule': {
734 'manual_scale_select_vim': False
736 'description': u'ompvm'
750 'image_file': u'sss',
762 'support_scaling': False,
765 'storage_policy': '',
768 'availability_zone': '',
774 'inject_data_list': [
781 'local_affinity_antiaffinity_rule': {
785 'manual_scale_select_vim': False
787 'description': u'ompvm'
801 'image_file': u'sss',
813 'support_scaling': False,
816 'storage_policy': '',
819 'availability_zone': '',
825 'inject_data_list': [
832 'local_affinity_antiaffinity_rule': {
836 'manual_scale_select_vim': False
838 'description': u'ompvm'
852 'image_file': u'sss',
864 'support_scaling': False,
867 'storage_policy': '',
870 'availability_zone': '',
876 'inject_data_list': [
883 'local_affinity_antiaffinity_rule': {
886 'template_id': u'10',
887 'manual_scale_select_vim': False
889 'description': u'ppvm'
903 'image_file': u'sss',
915 'support_scaling': False,
918 'storage_policy': '',
921 'availability_zone': '',
927 'inject_data_list': [
934 'local_affinity_antiaffinity_rule': {
937 'template_id': u'11',
938 'manual_scale_select_vim': False
940 'description': u'ppvm'
954 'image_file': u'sss',
966 'support_scaling': False,
969 'storage_policy': '',
972 'availability_zone': '',
978 'inject_data_list': [
985 'local_affinity_antiaffinity_rule': {
988 'template_id': u'12',
989 'manual_scale_select_vim': False
991 'description': u'ppvm'
1002 'policy_id': u'policy_scale_sss-vnf-template',
1004 'policy_file': '*-vnfd.zip/*-vnf-policy.xml'
1013 'name': u'opencos_sss_omm_img_release_20150723-1-disk1.vmdk',
1015 'disk_format': u'VMDK',
1016 'file_url': u'./zte-cn-sss-main-image/OMM/opencos_sss_omm_img_release_20150723-1-disk1.vmdk',
1017 'container_type': 'vm',
1019 'hypervisor_type': 'kvm'
1021 'image_file_id': u'opencos_sss_omm_img_release_20150723-1-disk1'
1026 'name': u'sss.vmdk',
1028 'disk_format': u'VMDK',
1029 'file_url': u'./zte-cn-sss-main-image/NE/sss.vmdk',
1030 'container_type': 'vm',
1032 'hypervisor_type': 'kvm'
1034 'image_file_id': u'sss'
1047 'domain_type': u'CN',
1048 'version': u'v4.14.10',
1049 'vmnumber_overquota_alarm': False,
1052 'vnfd_version': u'V00000001',
1053 'id': u'sss-vnf-template',
1054 'name': u'sss-vnf-template'
1063 "externalDataNetworkName": {
1087 "plugin_info": "vbrasplugin_1.0",
1089 "is_shared": "False",
1090 "request_reclassification": "False",
1091 "vnfd_version": "1.0.0",
1093 "nsh_aware": "True",
1094 "cross_dc": "False",
1095 "externalDataNetworkName": {
1096 "get_input": "externalDataNetworkName"
1118 "vl_id": "ext_mnet_network",
1121 "network_type": "vlan",
1122 "name": "externalMNetworkName",
1123 "dhcp_enabled": False,
1131 "end_ip": "190.168.100.100",
1132 "gateway_ip": "190.168.100.1",
1133 "start_ip": "190.168.100.2",
1134 "cidr": "190.168.100.0/24",
1136 "network_name": "sub_mnet",
1148 "invariant_id": "vbras_ns",
1149 "description": "vbras_ns",
1158 "vserver-id": "example-vserver-id-val-70924",
1159 "vserver-name": "example-vserver-name-val-61674",
1160 "vserver-name2": "example-vserver-name2-val-19234",
1161 "prov-status": "example-prov-status-val-94916",
1162 "vserver-selflink": "example-vserver-selflink-val-26562",
1164 "is-closed-loop-disabled": True,
1165 "resource-version": "1505465356263",
1169 "volume-id": "example-volume-id-val-71854",
1170 "volume-selflink": "example-volume-selflink-val-22433"
1177 "interface-name": "example-interface-name-val-24351",
1178 "interface-role": "example-interface-role-val-43242",
1179 "v6-wan-link-ip": "example-v6-wan-link-ip-val-4196",
1180 "selflink": "example-selflink-val-61295",
1181 "interface-id": "example-interface-id-val-95879",
1182 "macaddr": "example-macaddr-val-37302",
1183 "network-name": "example-network-name-val-44254",
1184 "management-option": "example-management-option-val-49009",
1185 "interface-description": "example-interface-description-val-99923",
1186 "is-port-mirrored": True,
1188 "prov-status": "example-prov-status-val-4698",
1189 "is-ip-unnumbered": True,
1190 "allowed-address-pairs": "example-allowed-address-pairs-val-5762",
1194 "vlan-interface": "example-vlan-interface-val-58193",
1195 "vlan-id-inner": 54452151,
1196 "vlan-id-outer": 70239293,
1197 "speed-value": "example-speed-value-val-18677",
1198 "speed-units": "example-speed-units-val-46185",
1199 "vlan-description": "example-vlan-description-val-81675",
1200 "backdoor-connection": "example-backdoor-connection-val-44608",
1201 "vpn-key": "example-vpn-key-val-7946",
1202 "orchestration-status": "example-orchestration-status-val-33611",
1204 "prov-status": "example-prov-status-val-8288",
1205 "is-ip-unnumbered": True,
1206 "l3-interface-ipv4-address-list": [
1208 "l3-interface-ipv4-address": "example-l3-interface-ipv4-address-val-25520",
1209 "l3-interface-ipv4-prefix-length": 69931928,
1210 "vlan-id-inner": 86628520,
1211 "vlan-id-outer": 62729236,
1212 "is-floating": True,
1213 "neutron-network-id": "example-neutron-network-id-val-64021",
1214 "neutron-subnet-id": "example-neutron-subnet-id-val-95049"
1217 "l3-interface-ipv6-address-list": [
1219 "l3-interface-ipv6-address": "example-l3-interface-ipv6-address-val-64310",
1220 "l3-interface-ipv6-prefix-length": 57919834,
1221 "vlan-id-inner": 79150122,
1222 "vlan-id-outer": 59789973,
1223 "is-floating": True,
1224 "neutron-network-id": "example-neutron-network-id-val-31713",
1225 "neutron-subnet-id": "example-neutron-subnet-id-val-89568"
1234 "pci-id": "example-pci-id-val-16747",
1235 "vf-vlan-filter": "example-vf-vlan-filter-val-4613",
1236 "vf-mac-filter": "example-vf-mac-filter-val-68168",
1237 "vf-vlan-strip": True,
1238 "vf-vlan-anti-spoof-check": True,
1239 "vf-mac-anti-spoof-check": True,
1240 "vf-mirrors": "example-vf-mirrors-val-6270",
1241 "vf-broadcast-allow": True,
1242 "vf-unknown-multicast-allow": True,
1243 "vf-unknown-unicast-allow": True,
1244 "vf-insert-stag": True,
1245 "vf-link-status": "example-vf-link-status-val-49266",
1246 "neutron-network-id": "example-neutron-network-id-val-29493"
1253 "interface-name": "example-interface-name-val-98222",
1254 "interface-role": "example-interface-role-val-78360",
1255 "v6-wan-link-ip": "example-v6-wan-link-ip-val-76921",
1256 "selflink": "example-selflink-val-27117",
1257 "interface-id": "example-interface-id-val-11260",
1258 "macaddr": "example-macaddr-val-60378",
1259 "network-name": "example-network-name-val-16258",
1260 "management-option": "example-management-option-val-35097",
1261 "interface-description": "example-interface-description-val-10475",
1262 "is-port-mirrored": True,
1264 "prov-status": "example-prov-status-val-65203",
1265 "is-ip-unnumbered": True,
1266 "allowed-address-pairs": "example-allowed-address-pairs-val-65028"
1270 "l3-interface-ipv4-address-list": [
1272 "l3-interface-ipv4-address": "example-l3-interface-ipv4-address-val-72779",
1273 "l3-interface-ipv4-prefix-length": 55956636,
1274 "vlan-id-inner": 98174431,
1275 "vlan-id-outer": 20372128,
1276 "is-floating": True,
1277 "neutron-network-id": "example-neutron-network-id-val-39596",
1278 "neutron-subnet-id": "example-neutron-subnet-id-val-51109"
1281 "l3-interface-ipv6-address-list": [
1283 "l3-interface-ipv6-address": "example-l3-interface-ipv6-address-val-95203",
1284 "l3-interface-ipv6-prefix-length": 57454747,
1285 "vlan-id-inner": 53421060,
1286 "vlan-id-outer": 16006050,
1287 "is-floating": True,
1288 "neutron-network-id": "example-neutron-network-id-val-54216",
1289 "neutron-subnet-id": "example-neutron-subnet-id-val-1841"
1299 "vnfm-id": "example-vnfm-id-val-97336",
1300 "vim-id": "zte_test",
1301 "certificate-url": "example-certificate-url-val-18046",
1302 "resource-version": "example-resource-version-val-42094",
1303 "esr-system-info-list": {
1304 "esr-system-info": [
1306 "esr-system-info-id": "example-esr-system-info-id-val-7713",
1307 "system-name": "example-system-name-val-19801",
1308 "type": "ztevnfmdriver",
1309 "vendor": "example-vendor-val-50079",
1310 "version": "example-version-val-93146",
1311 "service-url": "example-service-url-val-68090",
1312 "user-name": "example-user-name-val-14470",
1313 "password": "example-password-val-84190",
1314 "system-type": "example-system-type-val-42773",
1315 "protocal": "example-protocal-val-85736",
1316 "ssl-cacert": "example-ssl-cacert-val-33989",
1317 "ssl-insecure": True,
1318 "ip-address": "example-ip-address-val-99038",
1319 "port": "example-port-val-27323",
1320 "cloud-domain": "example-cloud-domain-val-55163",
1321 "default-tenant": "example-default-tenant-val-99383",
1322 "resource-version": "example-resource-version-val-15424"
1329 "cloud-owner": "example-cloud-owner-val-97336",
1330 "cloud-region-id": "example-cloud-region-id-val-35532",
1331 "cloud-type": "example-cloud-type-val-18046",
1332 "owner-defined-type": "example-owner-defined-type-val-9413",
1333 "cloud-region-version": "example-cloud-region-version-val-85706",
1334 "identity-url": "example-identity-url-val-71252",
1335 "cloud-zone": "example-cloud-zone-val-27112",
1336 "complex-name": "example-complex-name-val-85283",
1337 "sriov-automation": True,
1338 "cloud-extra-info": "example-cloud-extra-info-val-90854",
1339 "cloud-epa-caps": "example-cloud-epa-caps-val-2409",
1340 "resource-version": "example-resource-version-val-42094",
1341 "esr-system-info-list": {
1342 "esr-system-info": [
1344 "esr-system-info-id": "example-esr-system-info-id-val-7713",
1345 "system-name": "example-system-name-val-19801",
1346 "type": "example-type-val-24477",
1347 "vendor": "example-vendor-val-50079",
1348 "version": "example-version-val-93146",
1349 "service-url": "example-service-url-val-68090",
1350 "user-name": "example-user-name-val-14470",
1351 "password": "example-password-val-84190",
1352 "system-type": "example-system-type-val-42773",
1353 "protocal": "example-protocal-val-85736",
1354 "ssl-cacert": "example-ssl-cacert-val-33989",
1355 "ssl-insecure": True,
1356 "ip-address": "example-ip-address-val-99038",
1357 "port": "example-port-val-27323",
1358 "cloud-domain": "example-cloud-domain-val-55163",
1359 "default-tenant": "admin",
1360 "resource-version": "example-resource-version-val-15424"
1367 "csarId": "zte_vbras",
1370 "vnfPackageId": "zte_vbras",
1371 "vnfdProvider": "1",
1375 "vnfdModel": vnfd_model_dict,