diff options
author | Arundathi Patil <arundpil@in.ibm.com> | 2018-09-11 16:09:29 +0530 |
---|---|---|
committer | IBM602-PC0F1E3C\Arundathi <arundpil@in.ibm.com> | 2018-09-11 16:09:47 +0530 |
commit | eaa0dd2a148afd537cbe3961c5fa3e40b9221c94 (patch) | |
tree | 12ab10b35e48e1d0627cdb054936323e9fee615f /src | |
parent | 840ad7e75cb0526fd53c36af8eb2a8508eff60dd (diff) |
reference-dataform.component: added test case
Wrote test case to test and cover displayHandleVnfc function when vnfc
variable in mapping-editor.sevice is true.
Issue-ID: APPC-1064
Change-Id: Ia90c1c9a50540d32776f251f49444d0ac165f789
Signed-off-by: Arundathi Patil <arundpil@in.ibm.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/app/vnfs/build-artifacts/reference-dataform/reference-dataform.component.spec.ts | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/app/vnfs/build-artifacts/reference-dataform/reference-dataform.component.spec.ts b/src/app/vnfs/build-artifacts/reference-dataform/reference-dataform.component.spec.ts index e69b8f8..499de2a 100644 --- a/src/app/vnfs/build-artifacts/reference-dataform/reference-dataform.component.spec.ts +++ b/src/app/vnfs/build-artifacts/reference-dataform/reference-dataform.component.spec.ts @@ -1108,6 +1108,26 @@ describe('ReferenceDataformComponent', () => { expect(component.vnfcIdentifier).toBe('346'); })); + it('should test displayHideVnfc function vnfc is true', inject([MappingEditorService], (service: MappingEditorService) => { + component.referenceDataObject = { + action: 'ConfigScaleOut', + 'action-level': 'vnf', + scope: { + 'vnf-type': '', + 'vnfc-type-list': ['346'] + }, + 'template': 'Y', + vm: [], + 'device-protocol': '', + 'user-name': '', + 'port-number': '', + 'artifact-list': [] + }; + service.newObject = { vnfc: true}; + component.displayHideVnfc(); + expect(component.vnfcIdentifier).toBe(true); + })); + // afterEach(function() { // jasmine.DEFAULT_TIMEOUT_INTERVAL = originalTimeout; // }); |