diff options
author | Indrijeet kumar <indriku1@in.ibm.com> | 2020-02-25 13:34:53 +0530 |
---|---|---|
committer | Indrijeet kumar <indriku1@in.ibm.com> | 2020-02-25 13:35:01 +0530 |
commit | 87a32735c109d3c3802d91708b43fa405c7e1ee8 (patch) | |
tree | 7d8a6dc6d2df36c4dce5ae29429897591b6c37cf /ecomp-sdk | |
parent | f38b0f61055741546c86c1883c1aca88c5118056 (diff) |
test case written for dashboard component
test case written for dashboard component
Issue-ID: PORTAL-813
Change-Id: Ic7b3af95363ed289f2101469f1691eb8d0473dbd
Signed-off-by: Indrijeet Kumar <indriku1@in.ibm.com>
Diffstat (limited to 'ecomp-sdk')
-rw-r--r-- | ecomp-sdk/epsdk-app-overlay/src/main/webapp/ngapp/src/app/layout/dashboard/dashboard.component.spec.ts | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/ecomp-sdk/epsdk-app-overlay/src/main/webapp/ngapp/src/app/layout/dashboard/dashboard.component.spec.ts b/ecomp-sdk/epsdk-app-overlay/src/main/webapp/ngapp/src/app/layout/dashboard/dashboard.component.spec.ts index ba1583d8..1c883519 100644 --- a/ecomp-sdk/epsdk-app-overlay/src/main/webapp/ngapp/src/app/layout/dashboard/dashboard.component.spec.ts +++ b/ecomp-sdk/epsdk-app-overlay/src/main/webapp/ngapp/src/app/layout/dashboard/dashboard.component.spec.ts @@ -4,7 +4,6 @@ import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; import { DashboardComponent } from './dashboard.component'; import { DashboardModule } from './dashboard.module'; -import { CUSTOM_ELEMENTS_SCHEMA, NO_ERRORS_SCHEMA } from '@angular/core'; import { HttpClientTestingModule } from '@angular/common/http/testing'; describe('DashboardComponent', () => { @@ -32,4 +31,11 @@ describe('DashboardComponent', () => { it('should create', () => { expect(component).toBeTruthy(); }); + + it('should test the closeAlert method', () =>{ + component.alerts=[1,2,3,4,5]; + component.closeAlert(2); + expect(component.alerts).toEqual([1,3,4,5]); + }) + }); |