Merge "allow LOB multi-selection for vnf -fix test"
[vid.git] / vid-webpack-master / src / app / drawingBoard / service-planning / objectsToTree / shared.tree.service.spec.ts
1 import {HttpClientTestingModule} from "@angular/common/http/testing";
2 import {getTestBed, TestBed} from "@angular/core/testing";
3 import {NgReduxTestingModule} from "@angular-redux/store/testing";
4 import {SharedTreeService} from "./shared.tree.service";
5 import {ObjectToInstanceTreeService} from "./objectToInstanceTree/objectToInstanceTree.service";
6 import {ObjectToTreeService} from "./objectToTree.service";
7 import {DefaultDataGeneratorService} from "../../../shared/services/defaultDataServiceGenerator/default.data.generator.service";
8 import {DynamicInputsService} from "./dynamicInputs.service";
9 import {DialogService} from "ng2-bootstrap-modal";
10 import {VnfPopupService} from "../../../shared/components/genericFormPopup/genericFormServices/vnf/vnf.popup.service";
11 import {ControlGeneratorUtil} from "../../../shared/components/genericForm/formControlsServices/control.generator.util.service";
12 import {AaiService} from "../../../shared/services/aaiService/aai.service";
13 import {NetworkPopupService} from "../../../shared/components/genericFormPopup/genericFormServices/network/network.popup.service";
14 import {NetworkControlGenerator} from "../../../shared/components/genericForm/formControlsServices/networkGenerator/network.control.generator";
15 import {VfModulePopupService} from "../../../shared/components/genericFormPopup/genericFormServices/vfModule/vfModule.popup.service";
16 import {VfModuleControlGenerator} from "../../../shared/components/genericForm/formControlsServices/vfModuleGenerator/vfModule.control.generator";
17 import {VnfGroupControlGenerator} from "../../../shared/components/genericForm/formControlsServices/vnfGroupGenerator/vnfGroup.control.generator";
18 import {FeatureFlagsService} from "../../../shared/services/featureFlag/feature-flags.service";
19 import {VnfControlGenerator} from "../../../shared/components/genericForm/formControlsServices/vnfGenerator/vnf.control.generator";
20 import {NgRedux} from "@angular-redux/store";
21 import {GenericFormService} from "../../../shared/components/genericForm/generic-form.service";
22 import {FormBuilder} from "@angular/forms";
23 import {SdcUiComponentsModule} from "onap-ui-angular";
24 import {LogService} from "../../../shared/utils/log/log.service";
25 import {IframeService} from "../../../shared/utils/iframe.service";
26 import {BasicPopupService} from "../../../shared/components/genericFormPopup/genericFormServices/basic.popup.service";
27 import {VnfGroupPopupService} from "../../../shared/components/genericFormPopup/genericFormServices/vnfGroup/vnfGroup.popup.service";
28 import {DuplicateService} from "../duplicate/duplicate.service";
29 import {AppState} from "../../../shared/store/reducers";
30 import {MessageBoxService} from "../../../shared/components/messageBox/messageBox.service";
31 import {ErrorMsgService} from "../../../shared/components/error-msg/error-msg.service";
32 import {AuditInfoModalComponent} from "../../../shared/components/auditInfoModal/auditInfoModal.component";
33 import {ILevelNodeInfo} from "./models/basic.model.info";
34 import {VnfModelInfo} from "./models/vnf/vnf.model.info";
35 import {ServiceInstanceActions} from "../../../shared/models/serviceInstanceActions";
36 import each from "jest-each";
37 import {DrawingBoardModes} from "../drawing-board.modes";
38 import {ComponentInfoService} from "../component-info/component-info.service";
39 import {ComponentInfoModel, ComponentInfoType} from "../component-info/component-info-model";
40 import {ModelInformationItem} from "../../../shared/components/model-information/model-information.component";
41 import {VpnStepService} from "./models/vrf/vrfModal/vpnStep/vpn.step.service";
42 import {NetworkStepService} from "./models/vrf/vrfModal/networkStep/network.step.service";
43 import {VfModuleUpgradePopupService} from "../../../shared/components/genericFormPopup/genericFormServices/vfModuleUpgrade/vfModule.upgrade.popuop.service";
44 import {SharedControllersService} from "../../../shared/components/genericForm/formControlsServices/sharedControlles/shared.controllers.service";
45 import {ModalService} from "../../../shared/components/customModal/services/modal.service";
46 import {CreateDynamicComponentService} from "../../../shared/components/customModal/services/create-dynamic-component.service";
47
48 class MockAppStore<T> {
49   getState() {
50     return getStore()
51   }
52
53   dispatch() {
54   }
55 }
56
57
58
59
60 function getNodeWithData(menuAction:string){
61   const nodeData = {
62     menuActions: {}
63   };
64   nodeData['menuActions'][menuAction] =  {
65     method: (node, serviceModelId) => {}
66   };
67   const node = {
68     parent: {
69       data: nodeData,
70       parent: {
71         data: nodeData
72       }
73     }
74   };
75   return node
76 }
77
78 describe('Shared Tree Service', () => {
79   let injector;
80   let service: SharedTreeService;
81   let _objectToInstanceTreeService: ObjectToInstanceTreeService;
82   let store: NgRedux<AppState>;
83
84   beforeAll(done => (async () => {
85     TestBed.configureTestingModule({
86       imports: [HttpClientTestingModule, NgReduxTestingModule, SdcUiComponentsModule],
87       providers: [
88         SharedTreeService,
89         SharedControllersService,
90         ObjectToTreeService,
91         DefaultDataGeneratorService,
92         DialogService,
93         VnfPopupService,
94         ControlGeneratorUtil,
95         AaiService,
96         LogService,
97         BasicPopupService,
98         VnfGroupPopupService,
99         DuplicateService,
100         IframeService,
101         DynamicInputsService,
102         NetworkPopupService,
103         NetworkControlGenerator,
104         VfModulePopupService,
105         VfModuleUpgradePopupService,
106         VfModuleControlGenerator,
107         VnfGroupControlGenerator,
108         DialogService,
109         FeatureFlagsService,
110         VnfControlGenerator,
111         AaiService,
112         DialogService,
113         GenericFormService,
114         FormBuilder,
115         ErrorMsgService,
116         ObjectToInstanceTreeService,
117         ComponentInfoService,
118         NetworkStepService,
119         VpnStepService,
120         ModalService,
121         CreateDynamicComponentService,
122         {provide: NgRedux, useClass: MockAppStore}
123       ]
124     });
125     await TestBed.compileComponents();
126     injector = getTestBed();
127     service = injector.get(SharedTreeService);
128     _objectToInstanceTreeService = injector.get(ObjectToInstanceTreeService);
129     store = injector.get(NgRedux);
130   })().then(done).catch(done.fail));
131
132   test('SharedTreeService should be defined', () => {
133     expect(service).toBeDefined();
134   });
135
136   test('SharedTreeService upgradeBottomUp should call redux actions', () => {
137     const serviceModelId = "1a80c596-27e5-4ca9-b5bb-e03a7fd4c0fd";
138     const node = getNodeWithData("upgrade");
139     spyOn(node.parent.data.menuActions['upgrade'], 'method');
140     service.upgradeBottomUp(node, serviceModelId);
141     expect(node.parent.data.menuActions['upgrade'].method).toBeCalledWith(node.parent, serviceModelId);
142     expect(node.parent.data.menuActions['upgrade'].method).toBeCalledTimes(2);
143
144   });
145
146   test('SharedTreeService undoUpgradeBottomUp should call redux actions', () => {
147     const serviceModelId = "1a80c596-27e5-4ca9-b5bb-e03a7fd4c0fd";
148     const node = getNodeWithData("undoUpgrade");
149     spyOn(node.parent.data.menuActions['undoUpgrade'], 'method');
150     service.undoUpgradeBottomUp(node, serviceModelId);
151     expect(node.parent.data.menuActions['undoUpgrade'].method).toBeCalledWith(node.parent, serviceModelId);
152     expect(node.parent.data.menuActions['undoUpgrade'].method).toBeCalledTimes(2);
153   });
154
155   test('shouldShowDeleteInstanceWithChildrenModal should open modal if child exist with action create', () => {
156     jest.spyOn(MessageBoxService.openModal, 'next');
157     let foo = () => {
158
159     };
160     let node = <any>{
161       children: [{action: "Create"}, {action: "None"}],
162       data: {
163         typeName: 'VNF'
164       }
165     };
166     service.shouldShowDeleteInstanceWithChildrenModal(node, "serviceModelId", foo);
167     expect(MessageBoxService.openModal.next).toHaveBeenCalled();
168   });
169
170   each([
171     ['volumeGroups by entry name', "volumeGroups",
172       "2017488_pasqualevpe0..2017488PasqualeVpe..PASQUALE_vRE_BV..module-1", "2017488PasqualeVpe..PASQUALE_vRE_BV..module-1"],
173     ['vfmodule by customizationUuid', "vfModules",
174       "f7e7c365-60cf-49a9-9ebf-a1aa11b9d401", "2017488PasqualeVpe..PASQUALE_vRE_BV..module-1"],
175     ['vnf by customizationUuid', "vnfs",
176       "1da7b585-5e61-4993-b95e-8e6606c81e45", "2017-488_PASQUALE-vPE 0"],
177     ['vnfGroups by invariantUuid because no customizationUuid', "vnfGroups",
178       "4bb2e27e-ddab-4790-9c6d-1f731bc14a45", "groupingservicefortest..ResourceInstanceGroup..0"],
179   ]).test('modelByIdentifier should success: %s', (description, modelTypeName, modelUniqueIdOrName, expectedModelCustomizationName) => {
180     let serviceModelFromHierarchy =
181       getStore().service.serviceHierarchy["1a80c596-27e5-4ca9-b5bb-e03a7fd4c0fd"];
182
183     expect(service.modelByIdentifiers(serviceModelFromHierarchy, modelTypeName, modelUniqueIdOrName))
184       .toHaveProperty("modelCustomizationName", expectedModelCustomizationName);
185   });
186
187   each([
188     ['vfmodule by invariantUuid when there is customizationUuid', "vfModules", "7253ff5c-97f0-4b8b-937c-77aeb4d79aa1"],
189     ['network by non-existing modelUniqueIdOrName', "networks", "7253ff5c-97f0-4b8b-937c-77aeb4d79aa1"],
190     ['collectionResource has no resource', "collectionResources", "whatever"],
191     ['non-existing model-type', "fooBar", "whatever"],
192   ]).test('modelByIdentifier should fail: %s', (description, modelTypeName, modelUniqueIdOrName) => {
193     let serviceModelFromHierarchy =
194       getStore().service.serviceHierarchy["1a80c596-27e5-4ca9-b5bb-e03a7fd4c0fd"];
195
196     expect(service.modelByIdentifiers(serviceModelFromHierarchy, modelTypeName, modelUniqueIdOrName))
197       .toBeUndefined();
198   });
199
200   test('openAuditInfoModalInsideIframe should open modal for failed instance', () => {
201     jest.spyOn(AuditInfoModalComponent.openInstanceAuditInfoModal, 'next');
202
203     let modelInfoServiceMock: ILevelNodeInfo = new VnfModelInfo(null, null,
204       null, null, null, null, null,
205       null, null, null, null,null, null);
206     const modelMock = {"a": "a"};
207     const instanceMock = {"instance": "instance", "trackById": "123456789"};
208     const instanceTypeMock = "instanceTypeMock";
209     jest.spyOn(modelInfoServiceMock, 'getModel').mockReturnValue(modelMock);
210     let node = <any>{
211       data: {
212         modelId: '6b528779-44a3-4472-bdff-9cd15ec93450',
213         trackById: '1245df21',
214         isFailed: true
215       }
216     };
217     service.openAuditInfoModal(node, "serviceModelId", instanceMock, instanceTypeMock, <any>modelInfoServiceMock);
218     expect(AuditInfoModalComponent.openInstanceAuditInfoModal.next).toHaveBeenCalledWith(
219       {
220         "instance": instanceMock,
221         "instanceId": "serviceModelId",
222         "model": modelMock,
223         "type": instanceTypeMock
224       });
225   });
226   each([
227     ['undefined', 'Unlimited (default)', {}],
228     ['null', 'Unlimited (default)', {max:null}],
229     ['3', '3', {max:3}],
230     ]).
231   test("when there is %s max instances in model , shell return %s text", (desc, expected, model) =>{
232     expect(service.createMaximumToInstantiateModelInformationItem(model).values[0]).toBe(expected);
233   });
234
235   test('shouldShowDeleteInstanceWithChildrfenModal should not open modal if all childs with action None', () => {
236     let foo = () => {
237     };
238     spyOn(MessageBoxService.openModal, 'next');
239
240     let node = <any>{
241       children: [{action: "None"}, {action: "None"}],
242       data: {
243         typeName: 'VNF'
244       }
245     };
246     service.shouldShowDeleteInstanceWithChildrenModal(node, "serviceModelId", foo);
247     expect(MessageBoxService.openModal.next).not.toHaveBeenCalled();
248   });
249
250   test ('addGeneralInfoItems should return correct info - ordered',()=>{
251     let specificNetworkInfo = [
252       ModelInformationItem.createInstance('Network role', "network role 1, network role 2")
253     ];
254     const actualInfoModel: ComponentInfoModel = service.addGeneralInfoItems(specificNetworkInfo,ComponentInfoType.NETWORK, getNetworkModelInfoFromHierarchy(),getNetworkInstance());
255
256     let expectedGeneralInfo = [
257       ModelInformationItem.createInstance('Model version', '2.0'),
258       ModelInformationItem.createInstance('Model customization ID', 'customization-id-from-hierarchy'),
259       ModelInformationItem.createInstance('Instance ID', 'NETWORK4_INSTANCE_ID'),
260       ModelInformationItem.createInstance('Instance type', 'CONTRAIL30_HIMELGUARD'),
261       ModelInformationItem.createInstance('In maintenance', false),
262       ModelInformationItem.createInstance('Network role', 'network role 1, network role 2')
263     ];
264     expect(actualInfoModel.modelInfoItems).toEqual(expectedGeneralInfo);
265   });
266
267   each([
268     ['model version from hierarchy', null, getNetworkModelInfoFromHierarchy(), '2.0'],
269     ['undefined model', null, null, undefined],
270     ['model version from instance', getSelectedModelInfo(), null, '5.0'],
271     ['model version from instance', getSelectedModelInfo(), getNetworkModelInfoFromHierarchy(), '5.0'],
272   ]).
273   test ('getModelVersionEitherFromInstanceOrFromHierarchy should return %s ' ,
274     (description, instance, model, expectedResult) =>{
275     let actualResult = service.getModelVersionEitherFromInstanceOrFromHierarchy(instance, model);
276     expect(actualResult).toEqual(expectedResult);
277   });
278
279   each([
280     ['model CustomizationId from hierarchy', null, getNetworkModelInfoFromHierarchy(), 'customization-id-from-hierarchy'],
281     ['undefined model', null, null, undefined],
282     ['model CustomizationId from instance', getSelectedModelInfo(), null, 'model-customization-id-from-instance'],
283     ['model CustomizationId from instance', getSelectedModelInfo(), getNetworkModelInfoFromHierarchy(), 'model-customization-id-from-instance'],
284   ]).
285   test ('getCustomizationIdEitherFromInstanceOrFromHierarchy should return %s ' ,
286     (description, instance, model, expectedResult) =>{
287       let actualResult = service.getModelCustomizationIdEitherFromInstanceOrFromHierarchy(instance, model);
288       expect(actualResult).toEqual(expectedResult);
289     });
290
291   each([
292     ['UUID from instance', getSelectedModelInfo(), getNetworkModelInfoFromHierarchy(),"UUID-from-instance" ],
293     ['UUID from instance', getSelectedModelInfo(), null,"UUID-from-instance" ],
294     ['UUID from hierarchy', null, getNetworkModelInfoFromHierarchy(),"UUID-from-hierarchy" ],
295     ['UUID undefined', null, null, undefined],
296
297   ]).
298   test('getModelVersionIdEitherFromInstanceOrFromHierarchy should %s', (description, instance, model, expectedResult) => {
299     let actualUuid = service.getModelVersionIdEitherFromInstanceOrFromHierarchy(instance, model);
300     expect(actualUuid).toEqual(expectedResult);
301   });
302
303   each([
304     ['from instance', getSelectedModelInfo(), getNetworkModelInfoFromHierarchy(), 'invariantId-from-instance'],
305     ['from instance', getSelectedModelInfo(), null, 'invariantId-from-instance'],
306     ['from hierarchy', null, getNetworkModelInfoFromHierarchy(), 'invariantId-from-hierarchy'],
307     ['undefined', null, null, undefined],
308   ]).
309   test('getModelInvariantIdEitherFromInstanceOrFromHierarchy should return invariantId %s', (description, instance, model, expectedInvariantId) =>{
310     let actualInvariantId = service.getModelInvariantIdEitherFromInstanceOrFromHierarchy(instance, model);
311     expect(actualInvariantId).toEqual(expectedInvariantId);
312   });
313
314   test('statusProperties should be prop on node according to node properties', () => {
315
316     let node = service.addingStatusProperty({orchStatus: 'completed', provStatus: 'inProgress', type: 'VFmodule', instanceModelInfo:{modelVersion: '1'}, inMaint: false});
317     expect(node.statusProperties).toBeDefined();
318     expect(node.statusProperties).toEqual([Object({
319       key: 'Prov Status: ',
320       value: 'inProgress',
321       testId: 'provStatus'
322     }), Object({
323       key: 'Orch Status: ',
324       value: 'completed',
325       testId: 'orchStatus'
326     }),
327     Object({
328       key: 'Model Version: ',
329       value: '1',
330       testId: 'modelVersion'
331     })]);
332     node = service.addingStatusProperty({orchStatus: 'completed', provStatus: 'inProgress',type: 'VFmodule',  instanceModelInfo:{}, inMaint: true});
333     expect(node.statusProperties).toEqual([Object({
334       key: 'Prov Status: ',
335       value: 'inProgress',
336       testId: 'provStatus'
337     }), Object({
338       key: 'Orch Status: ',
339       value: 'completed',
340       testId: 'orchStatus'
341     }), Object({
342       key: 'Model Version: ',
343       value: undefined,
344       testId: 'modelVersion'
345     }), Object({
346       key: 'In-maintenance',
347       value: '',
348       testId: 'inMaint'
349     })
350 ]);
351   });
352   each([
353     ['version 2', '2', '2'],
354     ['undefined', null, undefined]
355   ]).
356   test('getNodeModelVersion should return %s',  (description, nodeVersion, expectedVersion) => {
357     let node = <any>{
358       instanceModelInfo:{
359         modelVersion: nodeVersion
360       }
361     };
362     let actualVersion = service.getNodeModelVersion(node);
363     expect(actualVersion).toEqual(expectedVersion);
364   });
365
366   each([
367     [false, 'method is not in menu actions', ServiceInstanceActions.None, DrawingBoardModes.EDIT, {}, true],
368     [false, 'there is no action in node', null, DrawingBoardModes.EDIT, {someMethod: "someValue"}, true],
369     [true, 'edit mode, action is none, method in menu action', ServiceInstanceActions.None, DrawingBoardModes.EDIT, {someMethod: "someValue"}, true],
370     [false, 'edit mode, action is none, method in menu action, macro service', ServiceInstanceActions.None, DrawingBoardModes.EDIT, {someMethod: "someValue"}, false],
371     [false, 'edit mode, action is not none, method in menu action', ServiceInstanceActions.Resume, DrawingBoardModes.EDIT, {someMethod: "someValue"}, true],
372     [false, 'edit mode, action is CREATE, method in menu action', ServiceInstanceActions.Resume, DrawingBoardModes.EDIT, {someMethod: "someValue"}, true]
373   ]).test('shouldShowButtonGeneric return %s if %s ', (expected, description, action, mode, menuActions, isALaCarte) => {
374     jest.spyOn(store, 'getState').mockReturnValue(<any>{
375       global: {
376         drawingBoardStatus: mode
377       },
378       service : {
379         serviceInstance: {
380           someModelId : {
381             isALaCarte
382           }
383         }
384
385       }
386     });
387     let node = <any>{
388       data:{
389         action: action,
390         menuActions: menuActions
391       },
392     };
393
394     let res = service.shouldShowButtonGeneric(node, "someMethod", "someModelId");
395     expect(res).toBe(expected);
396   });
397
398   const enableRemoveAndEditItemsDataProvider = [
399     ['Create action CREATE mode', DrawingBoardModes.CREATE ,ServiceInstanceActions.Create, true],
400     ['Create action VIEW mode',DrawingBoardModes.VIEW , ServiceInstanceActions.Create,false],
401     ['Create action RETRY_EDIT mode',DrawingBoardModes.RETRY_EDIT,  ServiceInstanceActions.Create,  true],
402     ['Create action EDIT mode',DrawingBoardModes.EDIT, ServiceInstanceActions.Create,  true],
403     ['Create action RETRY mode',DrawingBoardModes.RETRY, ServiceInstanceActions.Create,  false],
404     ['None action EDIT mode',DrawingBoardModes.EDIT,  ServiceInstanceActions.None, false],
405     ['None action RETRY_EDIT mode', DrawingBoardModes.RETRY_EDIT, ServiceInstanceActions.None, false]];
406   each(enableRemoveAndEditItemsDataProvider).test('shouldShowEditAndDelete if child exist with %s', (description, mode, action, enabled) => {
407     jest.spyOn(store, 'getState').mockReturnValue(<any>{
408         global: {
409           drawingBoardStatus: mode
410         }
411       });
412       let node = <any>{
413         data:{
414           action: action
415         },
416       };
417       let res = service.shouldShowRemoveAndEdit(node);
418       expect(res).toBe(enabled);
419     });
420
421
422   const isVfmoduleAlmostPartOfModelOnlyCustomizationUuidDifferProvider = [
423     ['node is part of model, but vfmodule diff by customization',
424       true, 'mDNS 01222020 0', '9fdc68e9-9f53-431c-b8a2-7e337b9a0d0a', '82160e6e-d9c4-45ef-bd19-01573ab11b61'],
425
426     ['vnf model-name not found',
427       false, 'mDNS 01222020 1', '9fdc68e9-9f53-431c-b8a2-7e337b9a0d0a', '82160e6e-d9c4-45ef-bd19-01573ab11b61'],
428
429     ['vfmodule invariant-id not found',
430       false, 'mDNS 01222020 0', 'wrong invariant-id', '82160e6e-d9c4-45ef-bd19-01573ab11b61'],
431
432     ['vfmodule customization-id match',
433       false, 'mDNS 01222020 0', '9fdc68e9-9f53-431c-b8a2-7e337b9a0d0a', 'c9b32003-febc-44e0-a97f-7630fa7fa4a0'],
434   ];
435
436   each(isVfmoduleAlmostPartOfModelOnlyCustomizationUuidDifferProvider).test('isVfmoduleAlmostPartOfModelOnlyCustomizationUuidDiffer: when  %s should return %s', (description, expected, vnfModelName, invariantUuid, customizationUuid) => {
437     const serviceModelId : string = 'a243da28-c11e-45a8-9f26-0284a9a789bc';
438     spyOn(store, 'getState').and.returnValue({
439       service : {
440         serviceHierarchy : {
441           [serviceModelId] : {
442             vnfs : {
443               [vnfModelName] : {
444                 vfModules : {
445                   vfModuleModelName : {
446                     invariantUuid : invariantUuid,
447                     customizationUuid : customizationUuid
448                   }
449                 }
450               }
451             }
452           }
453         }
454       }
455     });
456
457     const node = <any>{
458       data:{
459         modelInvariantId : '9fdc68e9-9f53-431c-b8a2-7e337b9a0d0a',
460         modelCustomizationId : 'c9b32003-febc-44e0-a97f-7630fa7fa4a0',
461         modelName : 'vfModuleModelName'
462       },
463       parent : {
464         data : {
465           modelName : "mDNS 01222020 0"
466         }
467       }
468     };
469
470     const isDiffCustomizationUuidResponse : boolean = service.isVfmoduleAlmostPartOfModelOnlyCustomizationUuidDiffer(node, serviceModelId);
471     expect(isDiffCustomizationUuidResponse).toEqual(expected);
472   });
473
474   each([
475     [false, true, true, false],
476     [true, true, true, true],
477     [true, true, false, true],
478     [true, false, true, true],
479     [true, false, false, false],
480   ]).
481   test('when flag is %s the UpdatedLatestVersion is %s and Vfmodule not exists on hierarchy is %s isShouldShowButtonGenericMustToBeCalled should return %s', (
482      flag: boolean,
483      isThereAnUpdatedLatestVersion: boolean,
484      isVfModuleCustomizationIdNotExistsOnModel: boolean,
485      isShouldShowButtonGenericMustToBeCalled: boolean
486      ) => {
487       let node = <any>  {};
488       let serviceModelId : string = '08c5fa17-769a-4231-bd92-aed4b0ed086d';
489       jest.spyOn(store, 'getState').mockReturnValue(<any>{
490         global: {
491           "flags": {
492             "FLAG_FLASH_REPLACE_VF_MODULE": flag,
493           },
494         }
495       });
496       spyOn(service, 'isThereAnUpdatedLatestVersion').and.returnValue(isThereAnUpdatedLatestVersion);
497       spyOn(service, 'isVfModuleCustomizationIdNotExistsOnModel').and.returnValue(isVfModuleCustomizationIdNotExistsOnModel);
498
499       expect(service.isVfMoudleCouldBeUpgraded(node, serviceModelId)).toEqual(isShouldShowButtonGenericMustToBeCalled);
500     });
501
502   each([
503     ['Vfm customization uuid not exists in model', 'not-existing-customization-uuid', 'service-model-id', true],
504     ['Vfm customization uuid exists in model', 'existing-customization-uuid', 'service-model-id', false]
505   ]).
506   test('%s when vfModuleNode is  %s and serviceModelId is %s ', (
507     description,
508     modelCustomizationId,
509     serviceModelId: string,
510     isExistsOnHierarchy: boolean,
511     ) => {
512
513     const vfModuleNode = { data: {
514         modelCustomizationId : modelCustomizationId
515       }};
516
517     jest.spyOn(store, 'getState').mockReturnValue(<any>{
518       service : {
519         "serviceHierarchy": {
520           [serviceModelId]: {
521             "vfModules": {
522               "module-1": {
523                 "customizationUuid": "3d7f41c8-333b-4fee-b50d-5687e9c2170f",
524               },
525               "module-2": {
526                 "customizationUuid": "existing-customization-uuid",
527               }
528             }
529           }
530         }
531       }
532     });
533     expect(service.isVfModuleCustomizationIdNotExistsOnModel(vfModuleNode, serviceModelId)).toEqual(isExistsOnHierarchy);
534
535
536   });
537
538 });
539
540 function getStore() {
541   return {
542     "global": {
543       "name": null,
544       "flags": {
545         "EMPTY_DRAWING_BOARD_TEST": false,
546         "FLAG_NETWORK_TO_ASYNC_INSTANTIATION": false,
547         "FLAG_ADD_MSO_TESTAPI_FIELD": true,
548         "FLAG_SERVICE_MODEL_CACHE": true,
549         "FLAG_SHOW_ASSIGNMENTS": true,
550         "FLAG_FABRIC_CONFIGURATION_ASSIGNMENTS": true,
551         "FLAG_A_LA_CARTE_AUDIT_INFO": true,
552         "FLAG_1810_CR_ADD_CLOUD_OWNER_TO_MSO_REQUEST": true,
553         "FLAG_PRESENT_PROVIDER_NETWORKS_ASSOCIATIONS": true,
554         "FLAG_1902_NEW_VIEW_EDIT": true,
555         "FLAG_1810_IDENTIFY_SERVICE_FOR_NEW_UI": false,
556         "FLAG_1902_VNF_GROUPING": true,
557         "FLAG_SHOW_VERIFY_SERVICE": true,
558         "FLAG_ASYNC_ALACARTE_VFMODULE": true,
559         "FLAG_ASYNC_ALACARTE_VNF": true,
560         "FLAG_1810_AAI_LOCAL_CACHE": true,
561         "FLAG_EXP_USE_DEFAULT_HOST_NAME_VERIFIER": false,
562         "FLAG_EXP_ANY_ALACARTE_NEW_INSTANTIATION_UI": false,
563         "FLAG_SUPPLEMENTARY_FILE": true,
564         "FLAG_5G_IN_NEW_INSTANTIATION_UI": true,
565         "FLAG_RESTRICTED_SELECT": false,
566         "FLAG_1810_CR_LET_SELECTING_COLLECTOR_TYPE_UNCONDITIONALLY": true
567       },
568       "drawingBoardStatus": "VIEW",
569       "type": "UPDATE_DRAWING_BOARD_STATUS"
570     },
571     "service": {
572       "serviceHierarchy": {
573         "1a80c596-27e5-4ca9-b5bb-e03a7fd4c0fd": {
574           "service": {
575             "uuid": "1a80c596-27e5-4ca9-b5bb-e03a7fd4c0fd",
576             "invariantUuid": "cdb90b57-ed78-4d44-a5b4-7f43a02ec632",
577             "name": "action-data",
578             "version": "1.0",
579             "toscaModelURL": null,
580             "category": "Network L1-3",
581             "serviceType": "pnf",
582             "serviceRole": "Testing",
583             "description": "PASQUALE vMX vPE based on Juniper 17.2 release. Updated with updated VF for v8.0 of VLM",
584             "serviceEcompNaming": "false",
585             "instantiationType": "Macro",
586             "inputs": {},
587             "vidNotions": {"instantiationUI": "legacy", "modelCategory": "other", "viewEditUI": "legacy"}
588           },
589           "vnfs": {
590             "2017-388_PASQUALE-vPE 1": {
591               "uuid": "0903e1c0-8e03-4936-b5c2-260653b96413",
592               "invariantUuid": "00beb8f9-6d39-452f-816d-c709b9cbb87d",
593               "description": "Name PASQUALE vPE Description The provider edge function for the PASQUALE service supported by the Junipers VMX product Category Router Vendor Juniper Vendor Release Code 17.2 Owners Mary Fragale. Updated 9-25 to use v8.0 of the Juniper Valid 2 VLM",
594               "name": "2017-388_PASQUALE-vPE",
595               "version": "1.0",
596               "customizationUuid": "280dec31-f16d-488b-9668-4aae55d6648a",
597               "inputs": {},
598               "commands": {},
599               "properties": {
600                 "vmxvre_retype": "RE-VMX",
601                 "vnf_config_template_version": "get_input:2017488_pasqualevpe0_vnf_config_template_version",
602                 "sriov44_net_id": "48d399b3-11ee-48a8-94d2-f0ea94d6be8d",
603                 "int_ctl_net_id": "2f323477-6936-4d01-ac53-d849430281d9",
604                 "vmxvpfe_sriov41_0_port_mac": "00:11:22:EF:AC:DF",
605                 "int_ctl_net_name": "VMX-INTXI",
606                 "vmx_int_ctl_prefix": "10.0.0.10",
607                 "sriov43_net_id": "da349ca1-6de9-4548-be88-2d88e99bfef5",
608                 "sriov42_net_id": "760669ba-013d-4d9b-b0e7-4151fe2e6279",
609                 "sriov41_net_id": "25ad52d5-c165-40f8-b3b0-ddfc2373280a",
610                 "nf_type": "vPE",
611                 "vmxvpfe_int_ctl_ip_1": "10.0.0.10",
612                 "is_AVPN_service": "false",
613                 "vmx_RSG_name": "vREXI-affinity",
614                 "vmx_int_ctl_forwarding": "l2",
615                 "vmxvre_oam_ip_0": "10.0.0.10",
616                 "vmxvpfe_sriov44_0_port_mac": "00:11:22:EF:AC:DF",
617                 "vmxvpfe_sriov41_0_port_vlanstrip": "false",
618                 "vmxvpfe_sriov42_0_port_vlanfilter": "4001",
619                 "vmxvpfe_sriov44_0_port_unknownunicastallow": "true",
620                 "vmxvre_image_name_0": "VRE-ENGINE_17.2-S2.1.qcow2",
621                 "vmxvre_instance": "0",
622                 "vmxvpfe_sriov43_0_port_mac": "00:11:22:EF:AC:DF",
623                 "vmxvre_flavor_name": "ns.c1r16d32.v5",
624                 "vmxvpfe_volume_size_0": "40.0",
625                 "vmxvpfe_sriov43_0_port_vlanfilter": "4001",
626                 "nf_naming": "{ecomp_generated_naming=true}",
627                 "multi_stage_design": "true",
628                 "nf_naming_code": "Navneet",
629                 "vmxvre_name_0": "vREXI",
630                 "vmxvpfe_sriov42_0_port_vlanstrip": "false",
631                 "vmxvpfe_volume_name_0": "vPFEXI_FBVolume",
632                 "vmx_RSG_id": "bd89a33c-13c3-4a04-8fde-1a57eb123141",
633                 "vmxvpfe_image_name_0": "VPE_ROUTING-ENGINE_17.2R1-S2.1.qcow2",
634                 "vmxvpfe_sriov43_0_port_unknownunicastallow": "true",
635                 "vmxvpfe_sriov44_0_port_unknownmulticastallow": "true",
636                 "vmxvre_console": "vidconsole",
637                 "vmxvpfe_sriov44_0_port_vlanfilter": "4001",
638                 "vmxvpfe_sriov42_0_port_mac": "00:11:22:EF:AC:DF",
639                 "vmxvpfe_volume_id_0": "47cede15-da2f-4397-a101-aa683220aff3",
640                 "vmxvpfe_sriov42_0_port_unknownmulticastallow": "true",
641                 "vmxvpfe_sriov44_0_port_vlanstrip": "false",
642                 "vf_module_id": "123",
643                 "nf_function": "JAI",
644                 "vmxvpfe_sriov43_0_port_unknownmulticastallow": "true",
645                 "vmxvre_int_ctl_ip_0": "10.0.0.10",
646                 "ecomp_generated_naming": "true",
647                 "AIC_CLLI": "get_input:2017488_pasqualevpe0_AIC_CLLI",
648                 "vnf_name": "mtnj309me6vre",
649                 "vmxvpfe_sriov41_0_port_unknownunicastallow": "true",
650                 "vmxvre_volume_type_1": "HITACHI",
651                 "vmxvpfe_sriov44_0_port_broadcastallow": "true",
652                 "vmxvre_volume_type_0": "HITACHI",
653                 "vmxvpfe_volume_type_0": "HITACHI",
654                 "vmxvpfe_sriov43_0_port_broadcastallow": "true",
655                 "bandwidth_units": "get_input:2017488_pasqualevpe0_bandwidth_units",
656                 "vnf_id": "123",
657                 "vmxvre_oam_prefix": "24",
658                 "availability_zone_0": "mtpocfo-kvm-az01",
659                 "ASN": "get_input:2017488_pasqualevpe0_ASN",
660                 "vmxvre_chassis_i2cid": "161",
661                 "vmxvpfe_name_0": "vPFEXI",
662                 "bandwidth": "get_input:2017488_pasqualevpe0_bandwidth",
663                 "availability_zone_max_count": "1",
664                 "vmxvre_volume_size_0": "45.0",
665                 "vmxvre_volume_size_1": "50.0",
666                 "vmxvpfe_sriov42_0_port_broadcastallow": "true",
667                 "vmxvre_oam_gateway": "10.0.0.10",
668                 "vmxvre_volume_name_1": "vREXI_FAVolume",
669                 "vmxvre_ore_present": "0",
670                 "vmxvre_volume_name_0": "vREXI_FBVolume",
671                 "vmxvre_type": "0",
672                 "vnf_instance_name": "get_input:2017488_pasqualevpe0_vnf_instance_name",
673                 "vmxvpfe_sriov41_0_port_unknownmulticastallow": "true",
674                 "oam_net_id": "b95eeb1d-d55d-4827-abb4-8ebb94941429",
675                 "vmx_int_ctl_len": "24",
676                 "vmxvpfe_sriov43_0_port_vlanstrip": "false",
677                 "vmxvpfe_sriov41_0_port_broadcastallow": "true",
678                 "vmxvre_volume_id_1": "6e86797e-03cd-4fdc-ba72-2957119c746d",
679                 "vmxvpfe_sriov41_0_port_vlanfilter": "4001",
680                 "nf_role": "Testing",
681                 "vmxvre_volume_id_0": "f4eacb79-f687-4e9d-b760-21847c8bb15a",
682                 "vmxvpfe_sriov42_0_port_unknownunicastallow": "true",
683                 "vmxvpfe_flavor_name": "ns.c20r16d25.v5"
684               },
685               "type": "VF",
686               "modelCustomizationName": "2017-388_PASQUALE-vPE 1",
687               "vfModules": {},
688               "volumeGroups": {},
689               "vfcInstanceGroups": {}
690             },
691             "2017-388_PASQUALE-vPE 0": {
692               "uuid": "afacccf6-397d-45d6-b5ae-94c39734b168",
693               "invariantUuid": "72e465fe-71b1-4e7b-b5ed-9496118ff7a8",
694               "description": "Name PASQUALE vPE Description The provider edge function for the PASQUALE service supported by the Junipers VMX product Category Router Vendor Juniper Vendor Release Code 17.2 Owners Mary Fragale. Updated 9-25 to use v8.0 of the Juniper Valid 2 VLM",
695               "name": "2017-388_PASQUALE-vPE",
696               "version": "4.0",
697               "customizationUuid": "b3c76f73-eeb5-4fb6-9d31-72a889f1811c",
698               "inputs": {},
699               "commands": {},
700               "properties": {
701                 "vmxvre_retype": "RE-VMX",
702                 "vnf_config_template_version": "get_input:2017488_pasqualevpe0_vnf_config_template_version",
703                 "sriov44_net_id": "48d399b3-11ee-48a8-94d2-f0ea94d6be8d",
704                 "int_ctl_net_id": "2f323477-6936-4d01-ac53-d849430281d9",
705                 "vmxvpfe_sriov41_0_port_mac": "00:11:22:EF:AC:DF",
706                 "int_ctl_net_name": "VMX-INTXI",
707                 "vmx_int_ctl_prefix": "10.0.0.10",
708                 "sriov43_net_id": "da349ca1-6de9-4548-be88-2d88e99bfef5",
709                 "sriov42_net_id": "760669ba-013d-4d9b-b0e7-4151fe2e6279",
710                 "sriov41_net_id": "25ad52d5-c165-40f8-b3b0-ddfc2373280a",
711                 "nf_type": "vPE",
712                 "vmxvpfe_int_ctl_ip_1": "10.0.0.10",
713                 "is_AVPN_service": "false",
714                 "vmx_RSG_name": "vREXI-affinity",
715                 "vmx_int_ctl_forwarding": "l2",
716                 "vmxvre_oam_ip_0": "10.0.0.10",
717                 "vmxvpfe_sriov44_0_port_mac": "00:11:22:EF:AC:DF",
718                 "vmxvpfe_sriov41_0_port_vlanstrip": "false",
719                 "vmxvpfe_sriov42_0_port_vlanfilter": "4001",
720                 "vmxvpfe_sriov44_0_port_unknownunicastallow": "true",
721                 "vmxvre_image_name_0": "VRE-ENGINE_17.2-S2.1.qcow2",
722                 "vmxvre_instance": "0",
723                 "vmxvpfe_sriov43_0_port_mac": "00:11:22:EF:AC:DF",
724                 "vmxvre_flavor_name": "ns.c1r16d32.v5",
725                 "vmxvpfe_volume_size_0": "40.0",
726                 "vmxvpfe_sriov43_0_port_vlanfilter": "4001",
727                 "nf_naming": "{ecomp_generated_naming=true}",
728                 "multi_stage_design": "true",
729                 "nf_naming_code": "Navneet",
730                 "vmxvre_name_0": "vREXI",
731                 "vmxvpfe_sriov42_0_port_vlanstrip": "false",
732                 "vmxvpfe_volume_name_0": "vPFEXI_FBVolume",
733                 "vmx_RSG_id": "bd89a33c-13c3-4a04-8fde-1a57eb123141",
734                 "vmxvpfe_image_name_0": "VPE_ROUTING-ENGINE_17.2R1-S2.1.qcow2",
735                 "vmxvpfe_sriov43_0_port_unknownunicastallow": "true",
736                 "vmxvpfe_sriov44_0_port_unknownmulticastallow": "true",
737                 "vmxvre_console": "vidconsole",
738                 "vmxvpfe_sriov44_0_port_vlanfilter": "4001",
739                 "vmxvpfe_sriov42_0_port_mac": "00:11:22:EF:AC:DF",
740                 "vmxvpfe_volume_id_0": "47cede15-da2f-4397-a101-aa683220aff3",
741                 "vmxvpfe_sriov42_0_port_unknownmulticastallow": "true",
742                 "vmxvpfe_sriov44_0_port_vlanstrip": "false",
743                 "vf_module_id": "123",
744                 "nf_function": "JAI",
745                 "vmxvpfe_sriov43_0_port_unknownmulticastallow": "true",
746                 "vmxvre_int_ctl_ip_0": "10.0.0.10",
747                 "ecomp_generated_naming": "true",
748                 "AIC_CLLI": "get_input:2017488_pasqualevpe0_AIC_CLLI",
749                 "vnf_name": "mtnj309me6vre",
750                 "vmxvpfe_sriov41_0_port_unknownunicastallow": "true",
751                 "vmxvre_volume_type_1": "HITACHI",
752                 "vmxvpfe_sriov44_0_port_broadcastallow": "true",
753                 "vmxvre_volume_type_0": "HITACHI",
754                 "vmxvpfe_volume_type_0": "HITACHI",
755                 "vmxvpfe_sriov43_0_port_broadcastallow": "true",
756                 "bandwidth_units": "get_input:2017488_pasqualevpe0_bandwidth_units",
757                 "vnf_id": "123",
758                 "vmxvre_oam_prefix": "24",
759                 "availability_zone_0": "mtpocfo-kvm-az01",
760                 "ASN": "get_input:2017488_pasqualevpe0_ASN",
761                 "vmxvre_chassis_i2cid": "161",
762                 "vmxvpfe_name_0": "vPFEXI",
763                 "bandwidth": "get_input:2017488_pasqualevpe0_bandwidth",
764                 "availability_zone_max_count": "1",
765                 "vmxvre_volume_size_0": "45.0",
766                 "vmxvre_volume_size_1": "50.0",
767                 "vmxvpfe_sriov42_0_port_broadcastallow": "true",
768                 "vmxvre_oam_gateway": "10.0.0.10",
769                 "vmxvre_volume_name_1": "vREXI_FAVolume",
770                 "vmxvre_ore_present": "0",
771                 "vmxvre_volume_name_0": "vREXI_FBVolume",
772                 "vmxvre_type": "0",
773                 "vnf_instance_name": "get_input:2017488_pasqualevpe0_vnf_instance_name",
774                 "vmxvpfe_sriov41_0_port_unknownmulticastallow": "true",
775                 "oam_net_id": "b95eeb1d-d55d-4827-abb4-8ebb94941429",
776                 "vmx_int_ctl_len": "24",
777                 "vmxvpfe_sriov43_0_port_vlanstrip": "false",
778                 "vmxvpfe_sriov41_0_port_broadcastallow": "true",
779                 "vmxvre_volume_id_1": "6e86797e-03cd-4fdc-ba72-2957119c746d",
780                 "vmxvpfe_sriov41_0_port_vlanfilter": "4001",
781                 "nf_role": "Testing",
782                 "vmxvre_volume_id_0": "f4eacb79-f687-4e9d-b760-21847c8bb15a",
783                 "vmxvpfe_sriov42_0_port_unknownunicastallow": "true",
784                 "vmxvpfe_flavor_name": "ns.c20r16d25.v5"
785               },
786               "type": "VF",
787               "modelCustomizationName": "2017-388_PASQUALE-vPE 0",
788               "vfModules": {},
789               "volumeGroups": {},
790               "vfcInstanceGroups": {}
791             },
792             "2017-488_PASQUALE-vPE 0": {
793               "uuid": "69e09f68-8b63-4cc9-b9ff-860960b5db09",
794               "invariantUuid": "72e465fe-71b1-4e7b-b5ed-9496118ff7a8",
795               "description": "Name PASQUALE vPE Description The provider edge function for the PASQUALE service supported by the Junipers VMX product Category Router Vendor Juniper Vendor Release Code 17.2 Owners Mary Fragale. Updated 9-25 to use v8.0 of the Juniper Valid 2 VLM",
796               "name": "2017-488_PASQUALE-vPE",
797               "version": "5.0",
798               "customizationUuid": "1da7b585-5e61-4993-b95e-8e6606c81e45",
799               "inputs": {},
800               "commands": {},
801               "properties": {
802                 "max_instances": 1,
803                 "vmxvre_retype": "RE-VMX",
804                 "vnf_config_template_version": "get_input:2017488_pasqualevpe0_vnf_config_template_version",
805                 "sriov44_net_id": "48d399b3-11ee-48a8-94d2-f0ea94d6be8d",
806                 "int_ctl_net_id": "2f323477-6936-4d01-ac53-d849430281d9",
807                 "vmxvpfe_sriov41_0_port_mac": "00:11:22:EF:AC:DF",
808                 "int_ctl_net_name": "VMX-INTXI",
809                 "vmx_int_ctl_prefix": "10.0.0.10",
810                 "sriov43_net_id": "da349ca1-6de9-4548-be88-2d88e99bfef5",
811                 "sriov42_net_id": "760669ba-013d-4d9b-b0e7-4151fe2e6279",
812                 "sriov41_net_id": "25ad52d5-c165-40f8-b3b0-ddfc2373280a",
813                 "nf_type": "vPE",
814                 "vmxvpfe_int_ctl_ip_1": "10.0.0.10",
815                 "is_AVPN_service": "false",
816                 "vmx_RSG_name": "vREXI-affinity",
817                 "vmx_int_ctl_forwarding": "l2",
818                 "vmxvre_oam_ip_0": "10.0.0.10",
819                 "vmxvpfe_sriov44_0_port_mac": "00:11:22:EF:AC:DF",
820                 "vmxvpfe_sriov41_0_port_vlanstrip": "false",
821                 "vmxvpfe_sriov42_0_port_vlanfilter": "4001",
822                 "vmxvpfe_sriov44_0_port_unknownunicastallow": "true",
823                 "vmxvre_image_name_0": "VRE-ENGINE_17.2-S2.1.qcow2",
824                 "vmxvre_instance": "0",
825                 "vmxvpfe_sriov43_0_port_mac": "00:11:22:EF:AC:DF",
826                 "vmxvre_flavor_name": "ns.c1r16d32.v5",
827                 "vmxvpfe_volume_size_0": "40.0",
828                 "vmxvpfe_sriov43_0_port_vlanfilter": "4001",
829                 "nf_naming": "{ecomp_generated_naming=true}",
830                 "multi_stage_design": "true",
831                 "nf_naming_code": "Navneet",
832                 "vmxvre_name_0": "vREXI",
833                 "vmxvpfe_sriov42_0_port_vlanstrip": "false",
834                 "vmxvpfe_volume_name_0": "vPFEXI_FBVolume",
835                 "vmx_RSG_id": "bd89a33c-13c3-4a04-8fde-1a57eb123141",
836                 "vmxvpfe_image_name_0": "VPE_ROUTING-ENGINE_17.2R1-S2.1.qcow2",
837                 "vmxvpfe_sriov43_0_port_unknownunicastallow": "true",
838                 "vmxvpfe_sriov44_0_port_unknownmulticastallow": "true",
839                 "vmxvre_console": "vidconsole",
840                 "vmxvpfe_sriov44_0_port_vlanfilter": "4001",
841                 "vmxvpfe_sriov42_0_port_mac": "00:11:22:EF:AC:DF",
842                 "vmxvpfe_volume_id_0": "47cede15-da2f-4397-a101-aa683220aff3",
843                 "vmxvpfe_sriov42_0_port_unknownmulticastallow": "true",
844                 "vmxvpfe_sriov44_0_port_vlanstrip": "false",
845                 "vf_module_id": "123",
846                 "nf_function": "JAI",
847                 "vmxvpfe_sriov43_0_port_unknownmulticastallow": "true",
848                 "vmxvre_int_ctl_ip_0": "10.0.0.10",
849                 "ecomp_generated_naming": "true",
850                 "AIC_CLLI": "get_input:2017488_pasqualevpe0_AIC_CLLI",
851                 "vnf_name": "mtnj309me6vre",
852                 "vmxvpfe_sriov41_0_port_unknownunicastallow": "true",
853                 "vmxvre_volume_type_1": "HITACHI",
854                 "vmxvpfe_sriov44_0_port_broadcastallow": "true",
855                 "vmxvre_volume_type_0": "HITACHI",
856                 "vmxvpfe_volume_type_0": "HITACHI",
857                 "vmxvpfe_sriov43_0_port_broadcastallow": "true",
858                 "bandwidth_units": "get_input:2017488_pasqualevpe0_bandwidth_units",
859                 "vnf_id": "123",
860                 "vmxvre_oam_prefix": "24",
861                 "availability_zone_0": "mtpocfo-kvm-az01",
862                 "ASN": "get_input:2017488_pasqualevpe0_ASN",
863                 "vmxvre_chassis_i2cid": "161",
864                 "vmxvpfe_name_0": "vPFEXI",
865                 "bandwidth": "get_input:2017488_pasqualevpe0_bandwidth",
866                 "availability_zone_max_count": "1",
867                 "vmxvre_volume_size_0": "45.0",
868                 "vmxvre_volume_size_1": "50.0",
869                 "vmxvpfe_sriov42_0_port_broadcastallow": "true",
870                 "vmxvre_oam_gateway": "10.0.0.10",
871                 "vmxvre_volume_name_1": "vREXI_FAVolume",
872                 "vmxvre_ore_present": "0",
873                 "vmxvre_volume_name_0": "vREXI_FBVolume",
874                 "vmxvre_type": "0",
875                 "vnf_instance_name": "get_input:2017488_pasqualevpe0_vnf_instance_name",
876                 "vmxvpfe_sriov41_0_port_unknownmulticastallow": "true",
877                 "oam_net_id": "b95eeb1d-d55d-4827-abb4-8ebb94941429",
878                 "vmx_int_ctl_len": "24",
879                 "vmxvpfe_sriov43_0_port_vlanstrip": "false",
880                 "vmxvpfe_sriov41_0_port_broadcastallow": "true",
881                 "vmxvre_volume_id_1": "6e86797e-03cd-4fdc-ba72-2957119c746d",
882                 "vmxvpfe_sriov41_0_port_vlanfilter": "4001",
883                 "nf_role": "Testing",
884                 "vmxvre_volume_id_0": "f4eacb79-f687-4e9d-b760-21847c8bb15a",
885                 "vmxvpfe_sriov42_0_port_unknownunicastallow": "true",
886                 "vmxvpfe_flavor_name": "ns.c20r16d25.v5"
887               },
888               "type": "VF",
889               "modelCustomizationName": "2017-488_PASQUALE-vPE 0",
890               "vfModules": {
891                 "2017488_pasqualevpe0..2017488PasqualeVpe..PASQUALE_vRE_BV..module-1": {
892                   "uuid": "25284168-24bb-4698-8cb4-3f509146eca5",
893                   "invariantUuid": "7253ff5c-97f0-4b8b-937c-77aeb4d79aa1",
894                   "customizationUuid": "f7e7c365-60cf-49a9-9ebf-a1aa11b9d401",
895                   "description": null,
896                   "name": "2017488PasqualeVpe..PASQUALE_vRE_BV..module-1",
897                   "version": "6",
898                   "modelCustomizationName": "2017488PasqualeVpe..PASQUALE_vRE_BV..module-1",
899                   "properties": {
900                     "minCountInstances": 0,
901                     "maxCountInstances": null,
902                     "initialCount": 0,
903                     "vfModuleLabel": "PASQUALE_vRE_BV",
904                     "baseModule": false
905                   },
906                   "inputs": {},
907                   "volumeGroupAllowed": true
908                 },
909                 "2017488_pasqualevpe0..2017488PasqualeVpe..PASQUALE_base_vPE_BV..module-0": {
910                   "uuid": "f8360508-3f17-4414-a2ed-6bc71161e8db",
911                   "invariantUuid": "b34833bb-6aa9-4ad6-a831-70b06367a091",
912                   "customizationUuid": "a55961b2-2065-4ab0-a5b7-2fcee1c227e3",
913                   "description": null,
914                   "name": "2017488PasqualeVpe..PASQUALE_base_vPE_BV..module-0",
915                   "version": "5",
916                   "modelCustomizationName": "2017488PasqualeVpe..PASQUALE_base_vPE_BV..module-0",
917                   "properties": {
918                     "minCountInstances": 1,
919                     "maxCountInstances": 1,
920                     "initialCount": 1,
921                     "vfModuleLabel": "PASQUALE_base_vPE_BV",
922                     "baseModule": true
923                   },
924                   "inputs": {},
925                   "volumeGroupAllowed": false
926                 },
927                 "2017488_pasqualevpe0..2017488PasqualeVpe..PASQUALE_vPFE_BV..module-2": {
928                   "uuid": "0a0dd9d4-31d3-4c3a-ae89-a02f383e6a9a",
929                   "invariantUuid": "eff8cc59-53a1-4101-aed7-8cf24ecf8339",
930                   "customizationUuid": "3cd946bb-50e0-40d8-96d3-c9023520b557",
931                   "description": null,
932                   "name": "2017488PasqualeVpe..PASQUALE_vPFE_BV..module-2",
933                   "version": "6",
934                   "modelCustomizationName": "2017488PasqualeVpe..PASQUALE_vPFE_BV..module-2",
935                   "properties": {
936                     "minCountInstances": 0,
937                     "maxCountInstances": null,
938                     "initialCount": 0,
939                     "vfModuleLabel": "PASQUALE_vPFE_BV",
940                     "baseModule": false
941                   },
942                   "inputs": {},
943                   "volumeGroupAllowed": true
944                 }
945               },
946               "volumeGroups": {
947                 "2017488_pasqualevpe0..2017488PasqualeVpe..PASQUALE_vRE_BV..module-1": {
948                   "uuid": "25284168-24bb-4698-8cb4-3f509146eca5",
949                   "invariantUuid": "7253ff5c-97f0-4b8b-937c-77aeb4d79aa1",
950                   "customizationUuid": "f7e7c365-60cf-49a9-9ebf-a1aa11b9d401",
951                   "description": null,
952                   "name": "2017488PasqualeVpe..PASQUALE_vRE_BV..module-1",
953                   "version": "6",
954                   "modelCustomizationName": "2017488PasqualeVpe..PASQUALE_vRE_BV..module-1",
955                   "properties": {
956                     "minCountInstances": 0,
957                     "maxCountInstances": null,
958                     "initialCount": 0,
959                     "vfModuleLabel": "PASQUALE_vRE_BV",
960                     "baseModule": false
961                   },
962                   "inputs": {}
963                 },
964                 "2017488_pasqualevpe0..2017488PasqualeVpe..PASQUALE_vPFE_BV..module-2": {
965                   "uuid": "0a0dd9d4-31d3-4c3a-ae89-a02f383e6a9a",
966                   "invariantUuid": "eff8cc59-53a1-4101-aed7-8cf24ecf8339",
967                   "customizationUuid": "3cd946bb-50e0-40d8-96d3-c9023520b557",
968                   "description": null,
969                   "name": "2017488PasqualeVpe..PASQUALE_vPFE_BV..module-2",
970                   "version": "6",
971                   "modelCustomizationName": "2017488PasqualeVpe..PASQUALE_vPFE_BV..module-2",
972                   "properties": {
973                     "minCountInstances": 0,
974                     "maxCountInstances": null,
975                     "initialCount": 0,
976                     "vfModuleLabel": "PASQUALE_vPFE_BV",
977                     "baseModule": false
978                   },
979                   "inputs": {}
980                 }
981               },
982               "vfcInstanceGroups": {}
983             }
984           },
985           "networks": {
986             "ExtVL 0": {
987               "uuid": "ddc3f20c-08b5-40fd-af72-c6d14636b986",
988               "invariantUuid": "379f816b-a7aa-422f-be30-17114ff50b7c",
989               "description": "ECOMP generic virtual link (network) base type for all other service-level and global networks",
990               "name": "ExtVL",
991               "version": "37.0",
992               "customizationUuid": "94fdd893-4a36-4d70-b16a-ec29c54c184f",
993               "inputs": {},
994               "commands": {},
995               "properties": {
996                 "network_assignments": "{is_external_network=false, ipv4_subnet_default_assignment={min_subnets_count=1}, ecomp_generated_network_assignment=false, ipv6_subnet_default_assignment={min_subnets_count=1}}",
997                 "exVL_naming": "{ecomp_generated_naming=true}",
998                 "network_flows": "{is_network_policy=false, is_bound_to_vpn=false}",
999                 "network_homing": "{ecomp_selected_instance_node_target=false}"
1000               },
1001               "type": "VL",
1002               "modelCustomizationName": "ExtVL 0"
1003             }
1004           },
1005           "collectionResources": {},
1006           "configurations": {},
1007           "fabricConfigurations": {},
1008           "serviceProxies": {},
1009           "vfModules": {
1010             "2017488_pasqualevpe0..2017488PasqualeVpe..PASQUALE_vRE_BV..module-1": {
1011               "uuid": "25284168-24bb-4698-8cb4-3f509146eca5",
1012               "invariantUuid": "7253ff5c-97f0-4b8b-937c-77aeb4d79aa1",
1013               "customizationUuid": "f7e7c365-60cf-49a9-9ebf-a1aa11b9d401",
1014               "description": null,
1015               "name": "2017488PasqualeVpe..PASQUALE_vRE_BV..module-1",
1016               "version": "6",
1017               "modelCustomizationName": "2017488PasqualeVpe..PASQUALE_vRE_BV..module-1",
1018               "properties": {
1019                 "minCountInstances": 0,
1020                 "maxCountInstances": null,
1021                 "initialCount": 0,
1022                 "vfModuleLabel": "PASQUALE_vRE_BV",
1023                 "baseModule": false
1024               },
1025               "inputs": {},
1026               "volumeGroupAllowed": true
1027             },
1028             "2017488_pasqualevpe0..2017488PasqualeVpe..PASQUALE_base_vPE_BV..module-0": {
1029               "uuid": "f8360508-3f17-4414-a2ed-6bc71161e8db",
1030               "invariantUuid": "b34833bb-6aa9-4ad6-a831-70b06367a091",
1031               "customizationUuid": "a55961b2-2065-4ab0-a5b7-2fcee1c227e3",
1032               "description": null,
1033               "name": "2017488PasqualeVpe..PASQUALE_base_vPE_BV..module-0",
1034               "version": "5",
1035               "modelCustomizationName": "2017488PasqualeVpe..PASQUALE_base_vPE_BV..module-0",
1036               "properties": {
1037                 "minCountInstances": 1,
1038                 "maxCountInstances": 1,
1039                 "initialCount": 1,
1040                 "vfModuleLabel": "PASQUALE_base_vPE_BV",
1041                 "baseModule": true
1042               },
1043               "inputs": {},
1044               "volumeGroupAllowed": false
1045             },
1046             "2017488_pasqualevpe0..2017488PasqualeVpe..PASQUALE_vPFE_BV..module-2": {
1047               "uuid": "0a0dd9d4-31d3-4c3a-ae89-a02f383e6a9a",
1048               "invariantUuid": "eff8cc59-53a1-4101-aed7-8cf24ecf8339",
1049               "customizationUuid": "3cd946bb-50e0-40d8-96d3-c9023520b557",
1050               "description": null,
1051               "name": "2017488PasqualeVpe..PASQUALE_vPFE_BV..module-2",
1052               "version": "6",
1053               "modelCustomizationName": "2017488PasqualeVpe..PASQUALE_vPFE_BV..module-2",
1054               "properties": {
1055                 "minCountInstances": 0,
1056                 "maxCountInstances": null,
1057                 "initialCount": 0,
1058                 "vfModuleLabel": "PASQUALE_vPFE_BV",
1059                 "baseModule": false
1060               },
1061               "inputs": {},
1062               "volumeGroupAllowed": true
1063             }
1064           },
1065           "volumeGroups": {
1066             "2017488_pasqualevpe0..2017488PasqualeVpe..PASQUALE_vRE_BV..module-1": {
1067               "uuid": "25284168-24bb-4698-8cb4-3f509146eca5",
1068               "invariantUuid": "7253ff5c-97f0-4b8b-937c-77aeb4d79aa1",
1069               "customizationUuid": "f7e7c365-60cf-49a9-9ebf-a1aa11b9d401",
1070               "description": null,
1071               "name": "2017488PasqualeVpe..PASQUALE_vRE_BV..module-1",
1072               "version": "6",
1073               "modelCustomizationName": "2017488PasqualeVpe..PASQUALE_vRE_BV..module-1",
1074               "properties": {
1075                 "minCountInstances": 0,
1076                 "maxCountInstances": null,
1077                 "initialCount": 0,
1078                 "vfModuleLabel": "PASQUALE_vRE_BV",
1079                 "baseModule": false
1080               },
1081               "inputs": {}
1082             },
1083             "2017488_pasqualevpe0..2017488PasqualeVpe..PASQUALE_vPFE_BV..module-2": {
1084               "uuid": "0a0dd9d4-31d3-4c3a-ae89-a02f383e6a9a",
1085               "invariantUuid": "eff8cc59-53a1-4101-aed7-8cf24ecf8339",
1086               "customizationUuid": "3cd946bb-50e0-40d8-96d3-c9023520b557",
1087               "description": null,
1088               "name": "2017488PasqualeVpe..PASQUALE_vPFE_BV..module-2",
1089               "version": "6",
1090               "modelCustomizationName": "2017488PasqualeVpe..PASQUALE_vPFE_BV..module-2",
1091               "properties": {
1092                 "minCountInstances": 0,
1093                 "maxCountInstances": null,
1094                 "initialCount": 0,
1095                 "vfModuleLabel": "PASQUALE_vPFE_BV",
1096                 "baseModule": false
1097               },
1098               "inputs": {}
1099             }
1100           },
1101           "pnfs": {},
1102           "vnfGroups": {
1103             "groupingservicefortest..ResourceInstanceGroup..0": {
1104               "type": "VnfGroup",
1105               "invariantUuid": "4bb2e27e-ddab-4790-9c6d-1f731bc14a45",
1106               "uuid": "daeb6568-cef8-417f-9075-ed259ce59f48",
1107               "version": "1",
1108               "name": "groupingservicefortest..ResourceInstanceGroup..0",
1109               "modelCustomizationName": "groupingservicefortest..ResourceInstanceGroup..0",
1110               "properties": {
1111                 "contained_resource_type": "VF",
1112                 "role": "SERVICE-ACCESS",
1113                 "function": "DATA",
1114                 "description": "DDD0",
1115                 "type": "LOAD-GROUP",
1116                 "ecomp_generated_naming": "true"
1117               },
1118               "members": {
1119                 "vdorothea_svc_vprs_proxy 0": {
1120                   "uuid": "65fadfa8-a0d9-443f-95ad-836cd044e26c",
1121                   "invariantUuid": "f4baae0c-b3a5-4ca1-a777-afbffe7010bc",
1122                   "description": "A Proxy for Service vDOROTHEA_Svc_vPRS",
1123                   "name": "vDOROTHEA_Svc_vPRS Service Proxy",
1124                   "version": "1.0",
1125                   "customizationUuid": "bdb63d23-e132-4ce7-af2c-a493b4cafac9",
1126                   "inputs": {},
1127                   "commands": {},
1128                   "properties": {},
1129                   "type": "Service Proxy",
1130                   "sourceModelUuid": "da7827a2-366d-4be6-8c68-a69153c61274",
1131                   "sourceModelInvariant": "24632e6b-584b-4f45-80d4-fefd75fd9f14",
1132                   "sourceModelName": "vDOROTHEA_Svc_vPRS"
1133                 }
1134               }
1135             },
1136             "groupingservicefortest..ResourceInstanceGroup..1": {
1137               "type": "VnfGroup",
1138               "invariantUuid": "a704112d-dbc6-4e56-8d4e-aec57e95ef9a",
1139               "uuid": "c2b300e6-45de-4e5e-abda-3032bee2de56",
1140               "version": "1",
1141               "name": "groupingservicefortest..ResourceInstanceGroup..1",
1142               "modelCustomizationName": "groupingservicefortest..ResourceInstanceGroup..1",
1143               "properties": {
1144                 "contained_resource_type": "VF",
1145                 "role": "SERVICE-ACCESS",
1146                 "function": "SIGNALING",
1147                 "description": "DDD1",
1148                 "type": "LOAD-GROUP",
1149                 "ecomp_generated_naming": "true"
1150               },
1151               "members": {
1152                 "tsbc0001vm001_svc_proxy 0": {
1153                   "uuid": "65fadfa8-a0d9-443f-95ad-836cd044e26c",
1154                   "invariantUuid": "f4baae0c-b3a5-4ca1-a777-afbffe7010bc",
1155                   "description": "A Proxy for Service tsbc0001vm001_Svc",
1156                   "name": "tsbc0001vm001_Svc Service Proxy",
1157                   "version": "1.0",
1158                   "customizationUuid": "3d814462-30fb-4c62-b997-9aa360d27ead",
1159                   "inputs": {},
1160                   "commands": {},
1161                   "properties": {},
1162                   "type": "Service Proxy",
1163                   "sourceModelUuid": "28aeb8f6-5620-4148-8bfb-a5fb406f0309",
1164                   "sourceModelInvariant": "c989ab9a-33c7-46ec-b521-1b2daef5f047",
1165                   "sourceModelName": "tsbc0001vm001_Svc"
1166                 }
1167               }
1168             }
1169           }
1170         },
1171         "b75e0d22-05ff-4448-9266-5f0d4e1dbbd6": {
1172           "service": {
1173             "uuid": "b75e0d22-05ff-4448-9266-5f0d4e1dbbd6",
1174             "invariantUuid": "5b9c0f33-eec1-484a-bf77-736a6644d7a8",
1175             "name": "Using VID for VoIP Network Instantiations Shani",
1176             "version": "1.0",
1177             "toscaModelURL": null,
1178             "category": "VoIP Call Control",
1179             "serviceType": "",
1180             "serviceRole": "",
1181             "description": "Using VID for VoIP Network Instantiations Shani",
1182             "serviceEcompNaming": "true",
1183             "instantiationType": "ClientConfig",
1184             "inputs": {},
1185             "vidNotions": {"instantiationUI": "legacy", "modelCategory": "other", "viewEditUI": "legacy"}
1186           },
1187           "vnfs": {},
1188           "networks": {
1189             "AIC30_CONTRAIL_BASIC 0": {
1190               "uuid": "ac815c68-35b7-4ea4-9d04-92d2f844b27c",
1191               "invariantUuid": "de01afb5-532b-451d-aac4-ff9ff0644060",
1192               "description": "Basic contrail 3.0.x L3 network for AIC 3.x sites. ",
1193               "name": "AIC30_CONTRAIL_BASIC",
1194               "version": "3.0",
1195               "customizationUuid": "e94d61f7-b4b2-489a-a4a7-30b1a1a80daf",
1196               "inputs": {},
1197               "commands": {},
1198               "properties": {
1199                 "network_assignments": "{is_external_network=false, ipv4_subnet_default_assignment={min_subnets_count=1}, ecomp_generated_network_assignment=false, ipv6_subnet_default_assignment={min_subnets_count=1}}",
1200                 "exVL_naming": "{ecomp_generated_naming=true}",
1201                 "network_flows": "{is_network_policy=false, is_bound_to_vpn=false}",
1202                 "network_scope": "Service",
1203                 "network_type": "AIC30_CONTRAIL_BASIC",
1204                 "network_technology": "Contrail",
1205                 "network_homing": "{ecomp_selected_instance_node_target=false}"
1206               },
1207               "type": "VL",
1208               "modelCustomizationName": "AIC30_CONTRAIL_BASIC 0"
1209             }
1210           },
1211           "collectionResources": {},
1212           "configurations": {},
1213           "fabricConfigurations": {},
1214           "serviceProxies": {},
1215           "vfModules": {},
1216           "volumeGroups": {},
1217           "pnfs": {},
1218           "vnfGroups": {}
1219         }
1220       },
1221       "serviceInstance": {
1222         "1a80c596-27e5-4ca9-b5bb-e03a7fd4c0fd": {
1223           "vnfs": {
1224             "2017-488_PASQUALE-vPE 0": {
1225               "action": "None",
1226               "inMaint": false,
1227               "rollbackOnFailure": "true",
1228               "originalName": "2017-488_PASQUALE-vPE 0",
1229               "isMissingData": false,
1230               "trackById": "stigekyxrqi",
1231               "vfModules": {
1232                 "2017488_pasqualevpe0..2017488PasqualeVpe..PASQUALE_base_vPE_BV..module-0": {
1233                   "2017488_pasqualevpe0..2017488PasqualeVpe..PASQUALE_base_vPE_BV..module-0gytfi": {
1234                     "isMissingData": false,
1235                     "sdncPreReload": null,
1236                     "modelInfo": {
1237                       "modelType": "VFmodule",
1238                       "modelInvariantId": "b34833bb-6aa9-4ad6-a831-70b06367a091",
1239                       "modelVersionId": "f8360508-3f17-4414-a2ed-6bc71161e8db",
1240                       "modelName": "2017488PasqualeVpe..PASQUALE_base_vPE_BV..module-0",
1241                       "modelVersion": "5",
1242                       "modelCustomizationId": "a55961b2-2065-4ab0-a5b7-2fcee1c227e3",
1243                       "modelCustomizationName": "2017488PasqualeVpe..PASQUALE_base_vPE_BV..module-0"
1244                     },
1245                     "instanceParams": [{}],
1246                     "trackById": "3oj23o7nupo"
1247                   }
1248                 }
1249               },
1250               "vnfStoreKey": "2017-488_PASQUALE-vPE 0",
1251               "uuid": "69e09f68-8b63-4cc9-b9ff-860960b5db09",
1252               "productFamilyId": "d8a6ed93-251c-47ca-adc9-86671fd19f4c",
1253               "lcpCloudRegionId": "AAIAIC25",
1254               "tenantId": "092eb9e8e4b7412e8787dd091bc58e86",
1255               "lineOfBusiness": "ONAP",
1256               "platformName": "xxx1",
1257               "modelInfo": {
1258                 "modelInvariantId": "72e465fe-71b1-4e7b-b5ed-9496118ff7a8",
1259                 "modelVersionId": "69e09f68-8b63-4cc9-b9ff-860960b5db09",
1260                 "modelName": "2017-488_PASQUALE-vPE",
1261                 "modelVersion": "5.0",
1262                 "modelCustomizationName": "2017-488_PASQUALE-vPE 0",
1263                 "modelCustomizationId": "1da7b585-5e61-4993-b95e-8e6606c81e45",
1264                 "uuid": "69e09f68-8b63-4cc9-b9ff-860960b5db09"
1265               },
1266               "legacyRegion": "11111111",
1267               "instanceParams": [{}]
1268             },
1269             "2017-388_PASQUALE-vPE 0": {
1270               "action": "Create",
1271               "inMaint": false,
1272               "rollbackOnFailure": "true",
1273               "originalName": "2017-388_PASQUALE-vPE 0",
1274               "isMissingData": false,
1275               "trackById": "nib719t5vca",
1276               "vfModules": {},
1277               "vnfStoreKey": "2017-388_PASQUALE-vPE 0",
1278               "productFamilyId": "d8a6ed93-251c-47ca-adc9-86671fd19f4c",
1279               "lcpCloudRegionId": "AAIAIC25",
1280               "legacyRegion": "11111",
1281               "tenantId": "092eb9e8e4b7412e8787dd091bc58e86",
1282               "platformName": "platform",
1283               "lineOfBusiness": "zzz1",
1284               "instanceParams": [{}],
1285               "modelInfo": {
1286                 "modelInvariantId": "72e465fe-71b1-4e7b-b5ed-9496118ff7a8",
1287                 "modelVersionId": "afacccf6-397d-45d6-b5ae-94c39734b168",
1288                 "modelName": "2017-388_PASQUALE-vPE",
1289                 "modelVersion": "4.0",
1290                 "modelCustomizationId": "b3c76f73-eeb5-4fb6-9d31-72a889f1811c",
1291                 "modelCustomizationName": "2017-388_PASQUALE-vPE 0",
1292                 "uuid": "afacccf6-397d-45d6-b5ae-94c39734b168"
1293               },
1294               "uuid": "afacccf6-397d-45d6-b5ae-94c39734b168"
1295             },
1296             "2017-388_PASQUALE-vPE 1": {
1297               "action": "None",
1298               "inMaint": false,
1299               "rollbackOnFailure": "true",
1300               "originalName": "2017-388_PASQUALE-vPE 1",
1301               "isMissingData": false,
1302               "trackById": "cv7l1ak8vpe",
1303               "vfModules": {},
1304               "vnfStoreKey": "2017-388_PASQUALE-vPE 1",
1305               "productFamilyId": "d8a6ed93-251c-47ca-adc9-86671fd19f4c",
1306               "lcpCloudRegionId": "AAIAIC25",
1307               "legacyRegion": "123",
1308               "tenantId": "092eb9e8e4b7412e8787dd091bc58e86",
1309               "platformName": "platform",
1310               "lineOfBusiness": "ONAP",
1311               "instanceParams": [{}],
1312               "modelInfo": {
1313                 "modelInvariantId": "00beb8f9-6d39-452f-816d-c709b9cbb87d",
1314                 "modelVersionId": "0903e1c0-8e03-4936-b5c2-260653b96413",
1315                 "modelName": "2017-388_PASQUALE-vPE",
1316                 "modelVersion": "1.0",
1317                 "modelCustomizationId": "280dec31-f16d-488b-9668-4aae55d6648a",
1318                 "modelCustomizationName": "2017-388_PASQUALE-vPE 1",
1319                 "uuid": "0903e1c0-8e03-4936-b5c2-260653b96413"
1320               },
1321               "uuid": "0903e1c0-8e03-4936-b5c2-260653b96413"
1322             }
1323           },
1324           "instanceParams": [{}],
1325           "validationCounter": 0,
1326           "existingNames": {"yoav": ""},
1327           "existingVNFCounterMap": {
1328             "69e09f68-8b63-4cc9-b9ff-860960b5db09": 1,
1329             "afacccf6-397d-45d6-b5ae-94c39734b168": 1,
1330             "0903e1c0-8e03-4936-b5c2-260653b96413": 1
1331           },
1332           "existingVnfGroupCounterMap": {
1333             "daeb6568-cef8-417f-9075-ed259ce59f48": 0,
1334             "c2b300e6-45de-4e5e-abda-3032bee2de56": -1
1335           },
1336           "existingNetworksCounterMap": {"ddc3f20c-08b5-40fd-af72-c6d14636b986": 1},
1337           "networks": {
1338             "ExtVL 0": {
1339               "inMaint": false,
1340               "rollbackOnFailure": "true",
1341               "originalName": "ExtVL 0",
1342               "isMissingData": false,
1343               "trackById": "s6okajvv2n8",
1344               "networkStoreKey": "ExtVL 0",
1345               "productFamilyId": "d8a6ed93-251c-47ca-adc9-86671fd19f4c",
1346               "lcpCloudRegionId": "AAIAIC25",
1347               "legacyRegion": "12355555",
1348               "tenantId": "092eb9e8e4b7412e8787dd091bc58e86",
1349               "platformName": "platform",
1350               "lineOfBusiness": null,
1351               "instanceParams": [{}],
1352               "modelInfo": {
1353                 "modelInvariantId": "379f816b-a7aa-422f-be30-17114ff50b7c",
1354                 "modelVersionId": "ddc3f20c-08b5-40fd-af72-c6d14636b986",
1355                 "modelName": "ExtVL",
1356                 "modelVersion": "37.0",
1357                 "modelCustomizationId": "94fdd893-4a36-4d70-b16a-ec29c54c184f",
1358                 "modelCustomizationName": "ExtVL 0",
1359                 "uuid": "ddc3f20c-08b5-40fd-af72-c6d14636b986"
1360               },
1361               "uuid": "ddc3f20c-08b5-40fd-af72-c6d14636b986"
1362             }
1363           },
1364           "vnfGroups": {
1365             "groupingservicefortest..ResourceInstanceGroup..0": {
1366               "inMaint": false,
1367               "rollbackOnFailure": "true",
1368               "originalName": "groupingservicefortest..ResourceInstanceGroup..0",
1369               "isMissingData": false,
1370               "trackById": "se0obn93qq",
1371               "vnfGroupStoreKey": "groupingservicefortest..ResourceInstanceGroup..0",
1372               "instanceName": "groupingservicefortestResourceInstanceGroup0",
1373               "instanceParams": [{}],
1374               "modelInfo": {
1375                 "modelInvariantId": "4bb2e27e-ddab-4790-9c6d-1f731bc14a45",
1376                 "modelVersionId": "daeb6568-cef8-417f-9075-ed259ce59f48",
1377                 "modelName": "groupingservicefortest..ResourceInstanceGroup..0",
1378                 "modelVersion": "1",
1379                 "modelCustomizationName": "groupingservicefortest..ResourceInstanceGroup..0",
1380                 "uuid": "daeb6568-cef8-417f-9075-ed259ce59f48"
1381               },
1382               "uuid": "daeb6568-cef8-417f-9075-ed259ce59f48"
1383             }
1384           },
1385           "instanceName": "yoav",
1386           "globalSubscriberId": "e433710f-9217-458d-a79d-1c7aff376d89",
1387           "subscriptionServiceType": "TYLER SILVIA",
1388           "owningEntityId": "d61e6f2d-12fa-4cc2-91df-7c244011d6fc",
1389           "productFamilyId": "d8a6ed93-251c-47ca-adc9-86671fd19f4c",
1390           "lcpCloudRegionId": "AAIAIC25",
1391           "tenantId": "092eb9e8e4b7412e8787dd091bc58e86",
1392           "aicZoneId": "ATL53",
1393           "pause": null,
1394           "projectName": "WATKINS",
1395           "rollbackOnFailure": "true",
1396           "bulkSize": 1,
1397           "aicZoneName": "AAIATLTE-ATL53",
1398           "owningEntityName": "WayneHolland",
1399           "testApi": "VNF_API",
1400           "isEcompGeneratedNaming": false,
1401           "tenantName": "USP-SIP-IC-24335-T-01",
1402           "modelInfo": {
1403             "modelInvariantId": "cdb90b57-ed78-4d44-a5b4-7f43a02ec632",
1404             "modelVersionId": "1a80c596-27e5-4ca9-b5bb-e03a7fd4c0fd",
1405             "modelName": "action-data",
1406             "modelVersion": "1.0",
1407             "uuid": "1a80c596-27e5-4ca9-b5bb-e03a7fd4c0fd"
1408           },
1409           "isALaCarte": false,
1410           "name": "action-data",
1411           "version": "1.0",
1412           "description": "PASQUALE vMX vPE based on Juniper 17.2 release. Updated with updated VF for v8.0 of VLM",
1413           "category": "Network L1-3",
1414           "uuid": "1a80c596-27e5-4ca9-b5bb-e03a7fd4c0fd",
1415           "invariantUuid": "cdb90b57-ed78-4d44-a5b4-7f43a02ec632",
1416           "serviceType": "pnf",
1417           "serviceRole": "Testing",
1418           "vidNotions": {"instantiationUI": "legacy", "modelCategory": "other", "viewEditUI": "legacy"},
1419           "isMultiStepDesign": true
1420         }
1421       },
1422       "lcpRegionsAndTenants": {
1423         "lcpRegionList": [{
1424           "id": "AAIAIC25",
1425           "name": "AAIAIC25 (AIC)",
1426           "isPermitted": true,
1427           "cloudOwner": "irma-aic"
1428         }, {"id": "hvf6", "name": "hvf6 (AIC)", "isPermitted": true, "cloudOwner": "irma-aic"}],
1429         "lcpRegionsTenantsMap": {
1430           "AAIAIC25": [{
1431             "id": "092eb9e8e4b7412e8787dd091bc58e86",
1432             "name": "USP-SIP-IC-24335-T-01",
1433             "isPermitted": true,
1434             "cloudOwner": "irma-aic"
1435           }],
1436           "hvf6": [{
1437             "id": "bae71557c5bb4d5aac6743a4e5f1d054",
1438             "name": "AIN Web Tool-15-D-testalexandria",
1439             "isPermitted": true,
1440             "cloudOwner": "irma-aic"
1441           }, {
1442             "id": "d0a3e3f2964542259d155a81c41aadc3",
1443             "name": "test-hvf6-09",
1444             "isPermitted": true,
1445             "cloudOwner": "irma-aic"
1446           }, {
1447             "id": "fa45ca53c80b492fa8be5477cd84fc2b",
1448             "name": "ro-T112",
1449             "isPermitted": true,
1450             "cloudOwner": "irma-aic"
1451           }, {
1452             "id": "cbb99fe4ada84631b7baf046b6fd2044",
1453             "name": "DN5242-Nov16-T3",
1454             "isPermitted": true,
1455             "cloudOwner": "irma-aic"
1456           }]
1457         }
1458       },
1459       "subscribers": [{
1460         "id": "ERICA5779-Subscriber-2",
1461         "name": "ERICA5779-Subscriber-2",
1462         "isPermitted": false
1463       }, {
1464         "id": "ERICA5779-Subscriber-3",
1465         "name": "ERICA5779-Subscriber-3",
1466         "isPermitted": false
1467       }, {
1468         "id": "ERICA5779-Subscriber-4",
1469         "name": "ERICA5779-Subscriber-5",
1470         "isPermitted": false
1471       }, {
1472         "id": "ERICA5779-TestSub-PWT-101",
1473         "name": "ERICA5779-TestSub-PWT-101",
1474         "isPermitted": false
1475       }, {
1476         "id": "ERICA5779-TestSub-PWT-102",
1477         "name": "ERICA5779-TestSub-PWT-102",
1478         "isPermitted": false
1479       }, {
1480         "id": "ERICA5779-TestSub-PWT-103",
1481         "name": "ERICA5779-TestSub-PWT-103",
1482         "isPermitted": false
1483       }, {
1484         "id": "31739f3e-526b-11e6-beb8-9e71128cae77",
1485         "name": "CRAIG/ROBERTS",
1486         "isPermitted": false
1487       }, {"id": "DHV1707-TestSubscriber-2", "name": "DALE BRIDGES", "isPermitted": false}, {
1488         "id": "jimmy-example",
1489         "name": "JimmyExampleCust-20161102",
1490         "isPermitted": false
1491       }, {"id": "jimmy-example2", "name": "JimmyExampleCust-20161103", "isPermitted": false}, {
1492         "id": "CAR_2020_ER",
1493         "name": "CAR_2020_ER",
1494         "isPermitted": true
1495       }, {
1496         "id": "a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb",
1497         "name": "Emanuel",
1498         "isPermitted": false
1499       }, {
1500         "id": "21014aa2-526b-11e6-beb8-9e71128cae77",
1501         "name": "JULIO ERICKSON",
1502         "isPermitted": false
1503       }, {
1504         "id": "DHV1707-TestSubscriber-1",
1505         "name": "LLOYD BRIDGES",
1506         "isPermitted": false
1507       }, {"id": "e433710f-9217-458d-a79d-1c7aff376d89", "name": "SILVIA ROBBINS", "isPermitted": true}],
1508       "productFamilies": null,
1509       "serviceTypes": {
1510         "e433710f-9217-458d-a79d-1c7aff376d89": [{
1511           "id": "17",
1512           "name": "JOHANNA_SANTOS",
1513           "isPermitted": false
1514         }, {"id": "16", "name": "LINDSEY", "isPermitted": false}, {
1515           "id": "2",
1516           "name": "Emanuel",
1517           "isPermitted": false
1518         }, {"id": "5", "name": "Kennedy", "isPermitted": false}, {
1519           "id": "14",
1520           "name": "SSD",
1521           "isPermitted": false
1522         }, {"id": "1", "name": "TYLER SILVIA", "isPermitted": true}, {
1523           "id": "12",
1524           "name": "VPMS",
1525           "isPermitted": false
1526         }, {"id": "3", "name": "vJamie", "isPermitted": false}, {
1527           "id": "0",
1528           "name": "vRichardson",
1529           "isPermitted": false
1530         }, {"id": "18", "name": "vCarroll", "isPermitted": false}, {
1531           "id": "9",
1532           "name": "vFLORENCE",
1533           "isPermitted": false
1534         }, {"id": "13", "name": "vWINIFRED", "isPermitted": false}, {
1535           "id": "10",
1536           "name": "vMNS",
1537           "isPermitted": false
1538         }, {"id": "15", "name": "vMOG", "isPermitted": false}, {
1539           "id": "8",
1540           "name": "vOTA",
1541           "isPermitted": false
1542         }, {"id": "11", "name": "vEsmeralda", "isPermitted": false}, {
1543           "id": "6",
1544           "name": "vPorfirio",
1545           "isPermitted": false
1546         }, {"id": "7", "name": "vVM", "isPermitted": false}, {"id": "4", "name": "vVoiceMail", "isPermitted": false}]
1547       },
1548       "aicZones": [
1549         {
1550           "id": "NFT1",
1551           "name": "NFTJSSSS-NFT1"
1552         },
1553         {
1554           "id": "JAG1",
1555           "name": "YUDFJULP-JAG1"
1556         },
1557         {
1558           "id": "YYY1",
1559           "name": "UUUAIAAI-YYY1"
1560         },
1561         {
1562           "id": "AVT1",
1563           "name": "AVTRFLHD-AVT1"
1564         },
1565         {
1566           "id": "ATL34",
1567           "name": "ATLSANAI-ATL34"
1568         }
1569       ],
1570       "categoryParameters": {
1571         "owningEntityList": [{
1572           "id": "aaa1",
1573           "name": "aaa1"
1574         }, {"id": "d61e6f2d-12fa-4cc2-91df-7c244011d6fc", "name": "WayneHolland"}, {
1575           "id": "Melissa",
1576           "name": "Melissa"
1577         }],
1578         "projectList": [{"id": "WATKINS", "name": "WATKINS"}, {"id": "x1", "name": "x1"}, {"id": "yyy1", "name": "yyy1"}],
1579         "lineOfBusinessList": [{"id": "ONAP", "name": "ONAP"}, {"id": "zzz1", "name": "zzz1"}],
1580         "platformList": [{"id": "platform", "name": "platform"}, {"id": "xxx1", "name": "xxx1"}]
1581       },
1582       "type": "UPDATE_LCP_REGIONS_AND_TENANTS"
1583     }
1584   }
1585 }
1586
1587
1588 function getNetworkModelInfoFromHierarchy(){
1589   return {
1590     "version": "2.0",
1591     "customizationUuid":"customization-id-from-hierarchy",
1592     "uuid": "UUID-from-hierarchy",
1593     "invariantUuid": "invariantId-from-hierarchy"
1594   }
1595 }
1596
1597 function getSelectedModelInfo() {
1598   return {
1599     "instanceModelInfo": {
1600       "modelVersion": "5.0",
1601       "modelCustomizationId": "model-customization-id-from-instance",
1602       "modelVersionId": "UUID-from-instance",
1603       "modelInvariantId": "invariantId-from-instance"
1604     }
1605   }
1606 }
1607 function getNetworkInstance() {
1608   return {
1609     "inMaint": false,
1610     "instanceId": "NETWORK4_INSTANCE_ID",
1611     "instanceType": "CONTRAIL30_HIMELGUARD",
1612   };
1613 }