1 import {getTestBed, TestBed} from '@angular/core/testing';
2 import {HttpClientTestingModule, HttpTestingController} from '@angular/common/http/testing';
3 import {FormBuilder, FormGroup} from '@angular/forms';
4 import {GenericFormPopupService} from "./generic-form-popup.service";
5 import {IframeService} from "../../utils/iframe.service";
6 import {NgRedux} from "@angular-redux/store";
7 import {ServicePopupService} from "./genericFormServices/service/service.popup.service";
8 import {BasicControlGenerator} from "../genericForm/formControlsServices/basic.control.generator";
9 import {AaiService} from "../../services/aaiService/aai.service";
10 import {ServiceControlGenerator} from "../genericForm/formControlsServices/service.control.generator";
11 import {GenericFormService} from "../genericForm/generic-form.service";
12 import {LogService} from "../../utils/log/log.service";
13 import {DefaultDataGeneratorService} from "../../services/defaultDataServiceGenerator/default.data.generator.service";
14 import {BasicPopupService} from "./genericFormServices/basic.popup.service";
15 import {ActivatedRoute} from "@angular/router";
16 import {UUIDData} from "./generic-form-popup.component";
17 import {ITreeNode} from "angular-tree-component/dist/defs/api";
18 import {NetworkPopupService} from "./genericFormServices/network/network.popup.service";
19 import {NetworkControlGenerator} from "../genericForm/formControlsServices/networkGenerator/network.control.generator";
20 import {VfModulePopuopService} from "./genericFormServices/vfModule/vfModule.popuop.service";
21 import {VfModuleControlGenerator} from "../genericForm/formControlsServices/vfModuleGenerator/vfModule.control.generator";
22 import {FeatureFlagsService} from "../../services/featureFlag/feature-flags.service";
23 import {VfModuleUpgradePopupService} from "./genericFormServices/vfModuleUpgrade/vfModule.upgrade.popuop.service";
25 class MockAppStore<T>{
31 "FLAG_NETWORK_TO_ASYNC_INSTANTIATION": false,
32 "FLAG_SHOW_ASSIGNMENTS": true,
33 "FLAG_FABRIC_CONFIGURATION_ASSIGNMENTS": true,
34 "FLAG_SHOW_VERIFY_SERVICE": false,
35 "FLAG_SERVICE_MODEL_CACHE": true,
36 "CREATE_INSTANCE_TEST": false,
37 "FLAG_SETTING_DEFAULTS_IN_DRAWING_BOARD": false,
38 "EMPTY_DRAWING_BOARD_TEST": false,
39 "FLAG_ADD_MSO_TESTAPI_FIELD": true
41 "type": "[FLAGS] Update"
45 "6e59c5de-f052-46fa-aa7e-2fca9d674c44": {
47 "uuid": "6e59c5de-f052-46fa-aa7e-2fca9d674c44",
48 "invariantUuid": "e49fbd11-e60c-4a8e-b4bf-30fbe8f4fcc0",
49 "name": "ComplexService",
51 "toscaModelURL": null,
52 "category": "Emanuel",
55 "description": "ComplexService",
56 "serviceEcompNaming": "false",
57 "instantiationType": "Macro",
59 "instantiationType": "Macro"
65 "uuid": "d6557200-ecf2-4641-8094-5393ae3aae60",
66 "invariantUuid": "4160458e-f648-4b30-a176-43881ffffe9e",
67 "description": "VSP_vGeraldine",
68 "name": "VF_vGeraldine",
70 "customizationUuid": "91415b44-753d-494c-926a-456a9172bbb9",
73 "serviceEcompNaming" : "true",
75 "ecomp_generated_naming": "false",
78 "gpb2_Internal2_mac": "00:11:22:EF:AC:DF",
79 "sctp-b-ipv6-egress_src_start_port": "0",
80 "sctp-a-ipv6-egress_rule_application": "any",
81 "Internal2_allow_transit": "true",
82 "sctp-b-IPv6_ethertype": "IPv6",
83 "sctp-a-egress_rule_application": "any",
84 "sctp-b-ingress_action": "pass",
85 "sctp-b-ingress_rule_protocol": "icmp",
86 "ncb2_Internal1_mac": "00:11:22:EF:AC:DF",
87 "sctp-b-ipv6-ingress-src_start_port": "0.0",
88 "ncb1_Internal2_mac": "00:11:22:EF:AC:DF",
89 "fsb_volume_size_0": "320.0",
90 "sctp-b-egress_src_addresses": "local",
91 "sctp-a-ipv6-ingress_ethertype": "IPv4",
92 "sctp-a-ipv6-ingress-dst_start_port": "0",
93 "sctp-b-ipv6-ingress_rule_application": "any",
94 "domain_name": "default-domain",
95 "sctp-a-ingress_rule_protocol": "icmp",
96 "sctp-b-egress-src_start_port": "0.0",
97 "sctp-a-egress_src_addresses": "local",
98 "sctp-b-display_name": "epc-sctp-b-ipv4v6-sec-group",
99 "sctp-a-egress-src_start_port": "0.0",
100 "sctp-a-ingress_ethertype": "IPv4",
101 "sctp-b-ipv6-ingress-dst_end_port": "65535",
102 "sctp-b-dst_subnet_prefix_v6": "::",
103 "nf_naming": "{ecomp_generated_naming=true}",
104 "sctp-a-ipv6-ingress_src_subnet_prefix": "0.0.0.0",
105 "sctp-b-egress-dst_start_port": "0.0",
106 "ncb_flavor_name": "nv.c20r64d1",
107 "gpb1_Internal1_mac": "00:11:22:EF:AC:DF",
108 "sctp-b-egress_dst_subnet_prefix_len": "0.0",
109 "Internal2_net_cidr": "10.0.0.10",
110 "sctp-a-ingress-dst_start_port": "0.0",
111 "sctp-a-egress-dst_start_port": "0.0",
112 "fsb1_Internal2_mac": "00:11:22:EF:AC:DF",
113 "sctp-a-egress_ethertype": "IPv4",
114 "vlc_st_service_mode": "in-network-nat",
115 "sctp-a-ipv6-egress_ethertype": "IPv4",
116 "sctp-a-egress-src_end_port": "65535.0",
117 "sctp-b-ipv6-egress_rule_application": "any",
118 "sctp-b-egress_action": "pass",
119 "sctp-a-ingress-src_subnet_prefix_len": "0.0",
120 "sctp-b-ipv6-ingress-src_end_port": "65535.0",
121 "sctp-b-name": "epc-sctp-b-ipv4v6-sec-group",
122 "fsb2_Internal1_mac": "00:11:22:EF:AC:DF",
123 "sctp-a-ipv6-ingress-src_start_port": "0.0",
124 "sctp-b-ipv6-egress_ethertype": "IPv4",
125 "Internal1_net_cidr": "10.0.0.10",
126 "sctp-a-egress_dst_subnet_prefix": "0.0.0.0",
127 "fsb_flavor_name": "nv.c20r64d1",
128 "sctp_rule_protocol": "132",
129 "sctp-b-ipv6-ingress_src_subnet_prefix_len": "0",
130 "sctp-a-ipv6-ingress_rule_application": "any",
131 "sctp-a-IPv6_ethertype": "IPv6",
132 "vlc2_Internal1_mac": "00:11:22:EF:AC:DF",
133 "vlc_st_virtualization_type": "virtual-machine",
134 "sctp-b-ingress-dst_start_port": "0.0",
135 "sctp-b-ingress-dst_end_port": "65535.0",
136 "sctp-a-ipv6-ingress-src_end_port": "65535.0",
137 "sctp-a-display_name": "epc-sctp-a-ipv4v6-sec-group",
138 "sctp-b-ingress_rule_application": "any",
139 "int2_sec_group_name": "int2-sec-group",
140 "vlc_flavor_name": "nd.c16r64d1",
141 "sctp-b-ipv6-egress_src_addresses": "local",
142 "vlc_st_interface_type_int1": "other1",
143 "sctp-b-egress-src_end_port": "65535.0",
144 "sctp-a-ipv6-egress-dst_start_port": "0",
145 "vlc_st_interface_type_int2": "other2",
146 "sctp-a-ipv6-egress_rule_protocol": "any",
147 "Internal2_shared": "false",
148 "sctp-a-ipv6-egress_dst_subnet_prefix_len": "0",
149 "Internal2_rpf": "disable",
150 "vlc1_Internal1_mac": "00:11:22:EF:AC:DF",
151 "sctp-b-ipv6-egress_src_end_port": "65535",
152 "sctp-a-ipv6-egress_src_addresses": "local",
153 "sctp-a-ingress-dst_end_port": "65535.0",
154 "sctp-a-ipv6-egress_src_end_port": "65535",
155 "Internal1_forwarding_mode": "l2",
156 "Internal2_dhcp": "false",
157 "sctp-a-dst_subnet_prefix_v6": "::",
158 "pxe_image_name": "MME_PXE-Boot_16ACP04_GA.qcow2",
159 "vlc_st_interface_type_gtp": "other0",
160 "ncb1_Internal1_mac": "00:11:22:EF:AC:DF",
161 "sctp-b-src_subnet_prefix_v6": "::",
162 "sctp-a-egress_dst_subnet_prefix_len": "0.0",
163 "int1_sec_group_name": "int1-sec-group",
164 "Internal1_dhcp": "false",
165 "sctp-a-ipv6-egress_dst_end_port": "65535",
166 "Internal2_forwarding_mode": "l2",
167 "fsb2_Internal2_mac": "00:11:22:EF:AC:DF",
168 "sctp-b-egress_dst_subnet_prefix": "0.0.0.0",
169 "Internal1_net_cidr_len": "17",
170 "gpb2_Internal1_mac": "00:11:22:EF:AC:DF",
171 "sctp-b-ingress-src_subnet_prefix_len": "0.0",
172 "sctp-a-ingress_dst_addresses": "local",
173 "sctp-a-egress_action": "pass",
174 "fsb_volume_type_0": "SF-Default-SSD",
175 "ncb2_Internal2_mac": "00:11:22:EF:AC:DF",
176 "vlc_st_interface_type_sctp_a": "left",
177 "vlc_st_interface_type_sctp_b": "right",
178 "sctp-a-src_subnet_prefix_v6": "::",
179 "vlc_st_version": "2",
180 "sctp-b-egress_ethertype": "IPv4",
181 "sctp-a-ingress_rule_application": "any",
182 "gpb1_Internal2_mac": "00:11:22:EF:AC:DF",
183 "instance_ip_family_v6": "v6",
184 "sctp-a-ipv6-egress_src_start_port": "0",
185 "sctp-b-ingress-src_start_port": "0.0",
186 "sctp-b-ingress_dst_addresses": "local",
187 "fsb1_Internal1_mac": "00:11:22:EF:AC:DF",
188 "vlc_st_interface_type_oam": "management",
189 "multi_stage_design": "true",
190 "oam_sec_group_name": "oam-sec-group",
191 "Internal2_net_gateway": "10.0.0.10",
192 "sctp-a-ipv6-ingress-dst_end_port": "65535",
193 "sctp-b-ipv6-egress-dst_start_port": "0",
194 "Internal1_net_gateway": "10.0.0.10",
195 "sctp-b-ipv6-egress_rule_protocol": "any",
196 "gtp_sec_group_name": "gtp-sec-group",
197 "sctp-a-ipv6-egress_dst_subnet_prefix": "0.0.0.0",
198 "sctp-b-ipv6-egress_dst_subnet_prefix_len": "0",
199 "sctp-a-ipv6-ingress_dst_addresses": "local",
200 "sctp-a-egress_rule_protocol": "icmp",
201 "sctp-b-ipv6-egress_action": "pass",
202 "sctp-a-ipv6-egress_action": "pass",
203 "Internal1_shared": "false",
204 "sctp-b-ipv6-ingress_rule_protocol": "any",
205 "Internal2_net_cidr_len": "17",
206 "sctp-a-name": "epc-sctp-a-ipv4v6-sec-group",
207 "sctp-a-ingress-src_end_port": "65535.0",
208 "sctp-b-ipv6-ingress_src_subnet_prefix": "0.0.0.0",
209 "sctp-a-egress-dst_end_port": "65535.0",
210 "sctp-a-ingress_action": "pass",
211 "sctp-b-egress_rule_protocol": "icmp",
212 "sctp-b-ipv6-ingress_action": "pass",
213 "vlc_st_service_type": "firewall",
214 "sctp-b-ipv6-egress_dst_end_port": "65535",
215 "sctp-b-ipv6-ingress-dst_start_port": "0",
216 "vlc2_Internal2_mac": "00:11:22:EF:AC:DF",
217 "vlc_st_availability_zone": "true",
218 "fsb_volume_image_name_1": "MME_FSB2_16ACP04_GA.qcow2",
219 "sctp-b-ingress-src_subnet_prefix": "0.0.0.0",
220 "sctp-a-ipv6-ingress_src_subnet_prefix_len": "0",
221 "Internal1_allow_transit": "true",
222 "gpb_flavor_name": "nv.c20r64d1",
223 "availability_zone_max_count": "1",
224 "fsb_volume_image_name_0": "MME_FSB1_16ACP04_GA.qcow2",
225 "sctp-b-ipv6-ingress_dst_addresses": "local",
226 "sctp-b-ipv6-egress_dst_subnet_prefix": "0.0.0.0",
227 "sctp-b-ipv6-ingress_ethertype": "IPv4",
228 "vlc1_Internal2_mac": "00:11:22:EF:AC:DF",
229 "sctp-a-ingress-src_subnet_prefix": "0.0.0.0",
230 "sctp-a-ipv6-ingress_action": "pass",
231 "Internal1_rpf": "disable",
232 "sctp-b-ingress_ethertype": "IPv4",
233 "sctp-b-egress_rule_application": "any",
234 "sctp-b-ingress-src_end_port": "65535.0",
235 "sctp-a-ipv6-ingress_rule_protocol": "any",
236 "sctp-a-ingress-src_start_port": "0.0",
237 "sctp-b-egress-dst_end_port": "65535.0"
240 "modelCustomizationName": "VF_vGeraldine 0",
242 "vf_vgeraldine0..VfVgeraldine..vflorence_vlc..module-1": {
243 "uuid": "522159d5-d6e0-4c2a-aa44-5a542a12a830",
244 "invariantUuid": "98a7c88b-b577-476a-90e4-e25a5871e02b",
245 "customizationUuid": "55b1be94-671a-403e-a26c-667e9c47d091",
247 "name": "VfVgeraldine..vflorence_vlc..module-1",
249 "modelCustomizationName": "VfVgeraldine..vflorence_vlc..module-1",
251 "minCountInstances": 0,
252 "maxCountInstances": null,
254 "vfModuleLabel": "vflorence_vlc"
257 "volumeGroupAllowed": true
259 "vf_vgeraldine0..VfVgeraldine..vflorence_gpb..module-2": {
260 "uuid": "41708296-e443-4c71-953f-d9a010f059e1",
261 "invariantUuid": "1cca90b8-3490-495e-87da-3f3e4c57d5b9",
262 "customizationUuid": "6add59e0-7fe1-4bc4-af48-f8812422ae7c",
264 "name": "VfVgeraldine..vflorence_gpb..module-2",
266 "modelCustomizationName": "VfVgeraldine..vflorence_gpb..module-2",
268 "minCountInstances": 0,
269 "maxCountInstances": null,
271 "vfModuleLabel": "vflorence_gpb"
274 "volumeGroupAllowed": false
276 "vf_vgeraldine0..VfVgeraldine..base_vflorence..module-0": {
277 "uuid": "a27f5cfc-7f12-4f99-af08-0af9c3885c87",
278 "invariantUuid": "a6f9e51a-2b35-416a-ae15-15e58d61f36d",
279 "customizationUuid": "f8c040f1-7e51-4a11-aca8-acf256cfd861",
281 "name": "VfVgeraldine..base_vflorence..module-0",
283 "modelCustomizationName": "VfVgeraldine..base_vflorence..module-0",
285 "minCountInstances": 1,
286 "maxCountInstances": 1,
288 "vfModuleLabel": "base_vflorence"
291 "volumeGroupAllowed": true
295 "vf_vgeraldine0..VfVgeraldine..base_vflorence..module-0": {
296 "uuid": "a27f5cfc-7f12-4f99-af08-0af9c3885c87",
297 "invariantUuid": "a6f9e51a-2b35-416a-ae15-15e58d61f36d",
298 "customizationUuid": "f8c040f1-7e51-4a11-aca8-acf256cfd861",
300 "name": "VfVgeraldine..base_vflorence..module-0",
302 "modelCustomizationName": "VfVgeraldine..base_vflorence..module-0",
304 "minCountInstances": 1,
305 "maxCountInstances": 1,
307 "vfModuleLabel": "base_vflorence"
312 "vfcInstanceGroups": {}
317 "uuid": "ddc3f20c-08b5-40fd-af72-c6d14636b986",
318 "invariantUuid": "379f816b-a7aa-422f-be30-17114ff50b7c",
319 "description": "ECOMP generic virtual link (network) base type for all other service-level and global networks",
322 "customizationUuid": "94fdd893-4a36-4d70-b16a-ec29c54c184f",
326 "ecomp_generated_naming": "false",
327 "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}}",
328 "exVL_naming": "{ecomp_generated_naming=true}",
329 "network_flows": "{is_network_policy=false, is_bound_to_vpn=false}",
330 "network_homing": "{ecomp_selected_instance_node_target=false}"
333 "modelCustomizationName": "ExtVL 0"
336 "collectionResources": {},
338 "Port Mirroring Configuration By Policy 0": {
339 "uuid": "b4398538-e89d-4f13-b33d-ca323434ba50",
340 "invariantUuid": "6ef0ca40-f366-4897-951f-abd65d25f6f7",
341 "description": "A port mirroring configuration by policy object",
342 "name": "Port Mirroring Configuration By Policy",
344 "customizationUuid": "3c3b7b8d-8669-4b3b-8664-61970041fad2",
348 "type": "Configuration",
349 "modelCustomizationName": "Port Mirroring Configuration By Policy 0",
351 "collectorNodes": null,
352 "configurationByPolicy": false
355 "serviceProxies": {},
357 "vf_vgeraldine0..VfVgeraldine..vflorence_vlc..module-1": {
358 "uuid": "522159d5-d6e0-4c2a-aa44-5a542a12a830",
359 "invariantUuid": "98a7c88b-b577-476a-90e4-e25a5871e02b",
360 "customizationUuid": "55b1be94-671a-403e-a26c-667e9c47d091",
362 "name": "VfVgeraldine..vflorence_vlc..module-1",
364 "modelCustomizationName": "VfVgeraldine..vflorence_vlc..module-1",
366 "minCountInstances": 0,
367 "maxCountInstances": null,
369 "vfModuleLabel": "vflorence_vlc"
372 "volumeGroupAllowed": true
374 "vf_vgeraldine0..VfVgeraldine..vflorence_gpb..module-2": {
375 "uuid": "41708296-e443-4c71-953f-d9a010f059e1",
376 "invariantUuid": "1cca90b8-3490-495e-87da-3f3e4c57d5b9",
377 "customizationUuid": "6add59e0-7fe1-4bc4-af48-f8812422ae7c",
379 "name": "VfVgeraldine..vflorence_gpb..module-2",
381 "modelCustomizationName": "VfVgeraldine..vflorence_gpb..module-2",
383 "minCountInstances": 0,
384 "maxCountInstances": null,
386 "vfModuleLabel": "vflorence_gpb"
389 "volumeGroupAllowed": false
391 "vf_vgeraldine0..VfVgeraldine..base_vflorence..module-0": {
392 "uuid": "a27f5cfc-7f12-4f99-af08-0af9c3885c87",
393 "invariantUuid": "a6f9e51a-2b35-416a-ae15-15e58d61f36d",
394 "customizationUuid": "f8c040f1-7e51-4a11-aca8-acf256cfd861",
396 "name": "VfVgeraldine..base_vflorence..module-0",
398 "modelCustomizationName": "VfVgeraldine..base_vflorence..module-0",
400 "minCountInstances": 1,
401 "maxCountInstances": 1,
403 "vfModuleLabel": "base_vflorence"
406 "volumeGroupAllowed": true
410 "vf_vgeraldine0..VfVgeraldine..base_vflorence..module-0": {
411 "uuid": "a27f5cfc-7f12-4f99-af08-0af9c3885c87",
412 "invariantUuid": "a6f9e51a-2b35-416a-ae15-15e58d61f36d",
413 "customizationUuid": "f8c040f1-7e51-4a11-aca8-acf256cfd861",
415 "name": "VfVgeraldine..base_vflorence..module-0",
417 "modelCustomizationName": "VfVgeraldine..base_vflorence..module-0",
419 "minCountInstances": 1,
420 "maxCountInstances": 1,
422 "vfModuleLabel": "base_vflorence"
431 "6e59c5de-f052-46fa-aa7e-2fca9d674c44": {
435 "rollbackOnFailure": "true",
437 "vf_vgeraldine0..VfVgeraldine..base_vflorence..module-0": {
438 "vf_vgeraldine0..VfVgeraldine..base_vflorence..module-0vmvzo": {
439 "isMissingData": false,
440 "sdncPreReload": null,
442 "modelType": "VFmodule",
443 "modelInvariantId": "a6f9e51a-2b35-416a-ae15-15e58d61f36d",
444 "modelVersionId": "a27f5cfc-7f12-4f99-af08-0af9c3885c87",
445 "modelName": "VfVgeraldine..base_vflorence..module-0",
447 "modelCustomizationId": "f8c040f1-7e51-4a11-aca8-acf256cfd861",
448 "modelCustomizationName": "VfVgeraldine..base_vflorence..module-0"
453 "trackById": "wmtm6sy2uj"
457 "isMissingData": true,
458 "originalName": "VF_vGeraldine 0",
459 "vnfStoreKey": "VF_vGeraldine 0",
460 "trackById": "p3wk448m5do",
461 "uuid": "d6557200-ecf2-4641-8094-5393ae3aae60",
462 "productFamilyId": "36b4733a-53f4-4cc8-8ff0-9172e5fc4b8e",
463 "lcpCloudRegionId": null,
465 "lineOfBusiness": null,
466 "platformName": null,
469 "modelInvariantId": "4160458e-f648-4b30-a176-43881ffffe9e",
470 "modelVersionId": "6e59c5de-f052-46fa-aa7e-2fca9d674c44",
471 "modelName": "VF_vGeraldine",
472 "modelVersion": "2.0",
473 "modelCustomizationName": "VF_vGeraldine 0"
480 "validationCounter": 1,
482 "existingVNFCounterMap": {
483 "d6557200-ecf2-4641-8094-5393ae3aae60": 1
485 "globalSubscriberId": "e433710f-9217-458d-a79d-1c7aff376d89",
486 "subscriptionServiceType": "TYLER SILVIA",
487 "owningEntityId": "d61e6f2d-12fa-4cc2-91df-7c244011d6fc",
488 "productFamilyId": "36b4733a-53f4-4cc8-8ff0-9172e5fc4b8e",
489 "lcpCloudRegionId": "hvf6",
490 "tenantId": "229bcdc6eaeb4ca59d55221141d01f8e",
493 "rollbackOnFailure": "true",
496 "modelInvariantId": "e49fbd11-e60c-4a8e-b4bf-30fbe8f4fcc0",
497 "modelVersionId": "6e59c5de-f052-46fa-aa7e-2fca9d674c44",
498 "modelName": "ComplexService",
499 "modelVersion": "1.0",
500 "uuid": "6e59c5de-f052-46fa-aa7e-2fca9d674c44"
503 "name": "ComplexService",
505 "description": "ComplexService",
506 "category": "Emanuel",
507 "uuid": "6e59c5de-f052-46fa-aa7e-2fca9d674c44",
508 "invariantUuid": "e49fbd11-e60c-4a8e-b4bf-30fbe8f4fcc0",
511 "isEcompGeneratedNaming": true,
512 "isMultiStepDesign": false
515 "lcpRegionsAndTenants": {
528 "lcpRegionsTenantsMap": {
531 "id": "092eb9e8e4b7412e8787dd091bc58e86",
532 "name": "USP-SIP-IC-24335-T-01",
538 "id": "bae71557c5bb4d5aac6743a4e5f1d054",
539 "name": "AIN Web Tool-15-D-testalexandria",
543 "id": "d0a3e3f2964542259d155a81c41aadc3",
544 "name": "test-hvf6-09",
548 "id": "fa45ca53c80b492fa8be5477cd84fc2b",
553 "id": "4914ab0ab3a743e58f0eefdacc1dde77",
554 "name": "DN5242-Nov21-T1",
558 "id": "d0a3e3f2964542259d155a81c41aadc3",
559 "name": "test-hvf6-09",
563 "id": "cbb99fe4ada84631b7baf046b6fd2044",
564 "name": "DN5242-Nov16-T3",
572 "id": "ebc3bc3d-62fd-4a3f-a037-f619df4ff034",
577 "id": "17cc1042-527b-11e6-beb8-9e71128cae77",
582 "id": "36b4733a-53f4-4cc8-8ff0-9172e5fc4b8e",
587 "id": "a4f6f2ae-9bf5-4ed7-b904-06b2099c4bd7",
588 "name": "Enhanced Services",
597 "id": "323d69d9-2efe-4r45-ay0a-89ea7ard4e6f",
598 "name": "vEsmeralda",
602 "id": "a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb",
607 "id": "d8a6ed93-251c-47ca-adc9-86671fd19f4c",
612 "id": "db171b8f-115c-4992-a2e3-ee04cae357e0",
632 "id": "e433710f-9217-458d-a79d-1c7aff376d89",
633 "name": "TYLER SILVIA",
637 "id": "b6a3f28c-eebf-494c-a900-055cc7c874ce",
647 "id": "0ee8c1bc-7cbd-4b0a-a1ac-e9999255abc1",
648 "name": "CARA Griffin",
652 "id": "c7611ebe-c324-48f1-8085-94aef0c6ef3d",
653 "name": "DARREN MCGEE",
657 "id": "e30755dc-5673-4b6b-9dcf-9abdd96b93d1",
663 "name": "vSalvatore",
667 "id": "d7bb0a21-66f2-4e6d-87d9-9ef3ced63ae4",
677 "id": "12a96a9d-4b4c-4349-a950-fe1159602621",
678 "name": "DARREN MCGEE",
683 "e433710f-9217-458d-a79d-1c7aff376d89": [
686 "name": "vRichardson",
691 "name": "TYLER SILVIA",
706 "name": "vVoiceMail",
741 "name": "vEsmeralda",
771 "name": "JOHANNA_SANTOS",
784 "name": "NFTJSSSS-NFT1"
788 "name": "YUDFJULP-JAG1"
792 "name": "UUUAIAAI-YYY1"
796 "name": "AVTRFLHD-AVT1"
800 "name": "ATLSANAI-ATL34"
803 "categoryParameters": {
804 "owningEntityList": [
810 "id": "d61e6f2d-12fa-4cc2-91df-7c244011d6fc",
811 "name": "WayneHolland"
832 "lineOfBusinessList": [
853 "type": "[LCP_REGIONS_AND_TENANTS] Update",
857 "name": "CAR_2020_ER",
861 "id": "21014aa2-526b-11e6-beb8-9e71128cae77",
862 "name": "JULIO ERICKSON",
866 "id": "DHV1707-TestSubscriber-2",
867 "name": "DALE BRIDGES",
871 "id": "DHV1707-TestSubscriber-1",
872 "name": "LLOYD BRIDGES",
876 "id": "jimmy-example",
877 "name": "JimmyExampleCust-20161102",
881 "id": "jimmy-example2",
882 "name": "JimmyExampleCust-20161103",
886 "id": "ERICA5779-TestSub-PWT-102",
887 "name": "ERICA5779-TestSub-PWT-102",
891 "id": "ERICA5779-TestSub-PWT-101",
892 "name": "ERICA5779-TestSub-PWT-101",
896 "id": "a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb",
901 "id": "ERICA5779-Subscriber-4",
902 "name": "ERICA5779-Subscriber-5",
906 "id": "ERICA5779-TestSub-PWT-103",
907 "name": "ERICA5779-TestSub-PWT-103",
911 "id": "ERICA5779-Subscriber-2",
912 "name": "ERICA5779-Subscriber-2",
916 "id": "e433710f-9217-458d-a79d-1c7aff376d89",
917 "name": "SILVIA ROBBINS",
921 "id": "ERICA5779-Subscriber-3",
922 "name": "ERICA5779-Subscriber-3",
926 "id": "31739f3e-526b-11e6-beb8-9e71128cae77",
927 "name": "CRAIG/ROBERTS",
935 class ActivatedRouteMock<T>{
938 serviceModelId : '6e59c5de-f052-46fa-aa7e-2fca9d674c44'
943 class MockFeatureFlagsService {}
945 describe('Generic Form popup Service', () => {
947 let service: GenericFormPopupService;
948 let httpMock: HttpTestingController;
949 let form : FormGroup;
950 let fb : FormBuilder;
951 let netwokPopupService : NetworkPopupService;
952 let vfModulePopupService : VfModulePopuopService;
953 let servicePopupService : ServicePopupService;
954 let _aaiService : AaiService;
955 let _activatedRoute : ActivatedRoute;
957 beforeAll(done => (async () => {
958 TestBed.configureTestingModule({
959 imports: [HttpClientTestingModule],
960 providers: [GenericFormPopupService,
964 BasicControlGenerator,
965 ServiceControlGenerator,
968 DefaultDataGeneratorService,
972 NetworkControlGenerator,
973 VfModulePopuopService,
974 VfModuleUpgradePopupService,
975 VfModuleControlGenerator,
976 {provide:FeatureFlagsService, useClass: MockFeatureFlagsService},
977 {provide: ActivatedRoute, useClass: ActivatedRouteMock},
978 {provide: NgRedux, useClass: MockAppStore}]
980 await TestBed.compileComponents();
982 injector = getTestBed();
983 service = injector.get(GenericFormPopupService);
984 httpMock = injector.get(HttpTestingController);
985 fb = injector.get(FormBuilder);
986 netwokPopupService = injector.get(NetworkPopupService);
987 vfModulePopupService = injector.get(VfModulePopuopService);
988 servicePopupService = injector.get(ServicePopupService);
989 _aaiService = injector.get(AaiService);
990 _activatedRoute = injector.get(ActivatedRoute);
992 })().then(done).catch(done.fail));
995 test('VL: getGenericFormDetails should return FormPopupDetails', () => {
996 let uuidData : UUIDData = <any>{
998 serviceId : '6e59c5de-f052-46fa-aa7e-2fca9d674c44',
999 networkId : 'ExtVL 0',
1000 networkStoreKey : 'ExtVL 0',
1001 popupService : netwokPopupService
1003 let node : ITreeNode = <any>{data : {} };
1005 jest.spyOn(uuidData.popupService ,'getGenericFormPopupDetails');
1006 service.getGenericFormDetails(uuidData, node,true);
1008 expect(uuidData.popupService.getGenericFormPopupDetails).toHaveBeenCalledTimes(1);
1009 expect(uuidData.popupService.getGenericFormPopupDetails).toHaveBeenCalledWith(uuidData['serviceId'],
1010 uuidData['networkId'],
1011 uuidData['networkStoreKey'],
1018 test('VFmodule: getGenericFormDetails should return FormPopupDetails', () => {
1019 let uuidData : UUIDData = <any>{
1021 serviceId : '6e59c5de-f052-46fa-aa7e-2fca9d674c44',
1022 vnfStoreKey : 'VF_vGeraldine 0',
1023 vFModuleStoreKey : 'vf_vgeraldine0..VfVgeraldine..vflorence_vlc..module-1',
1024 popupService : vfModulePopupService
1026 let node : ITreeNode = <any>{data : {}};
1028 spyOn(uuidData.popupService ,'getGenericFormPopupDetails');
1029 service.getGenericFormDetails(uuidData, node,true);
1031 expect(uuidData.popupService.getGenericFormPopupDetails).toHaveBeenCalledTimes(1)
1032 expect(uuidData.popupService.getGenericFormPopupDetails).toHaveBeenCalledWith(
1033 uuidData['serviceId'],
1034 uuidData['vnfStoreKey'],
1035 uuidData['vFModuleStoreKey'],
1043 test('service: getGenericFormDetails should return FormPopupDetails', () => {
1044 let uuidData : UUIDData = <any>{
1046 serviceId : '6e59c5de-f052-46fa-aa7e-2fca9d674c44',
1047 popupService : servicePopupService
1049 let node : ITreeNode = <any>{data : {}};
1051 jest.spyOn(uuidData.popupService ,'getGenericFormPopupDetails');
1052 service.getGenericFormDetails(uuidData, node,true);
1054 expect(uuidData.popupService.getGenericFormPopupDetails).toHaveBeenCalledTimes(1);
1055 expect(uuidData.popupService.getGenericFormPopupDetails).toHaveBeenCalledWith(
1056 uuidData['serviceId'],
1066 test('initReduxOnCreateNewService',() => {
1067 jest.spyOn(_aaiService, 'getServiceModelById');
1068 service.initReduxOnCreateNewService();