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