summaryrefslogtreecommitdiffstats
path: root/ecomp-sdk
diff options
context:
space:
mode:
authorIndrijeet kumar <indriku1@in.ibm.com>2020-02-24 12:40:14 +0530
committerIndrijeet kumar <indriku1@in.ibm.com>2020-02-24 12:40:23 +0530
commitf2bd6fd5f2d9530a68b4966164e491a861e7ff90 (patch)
tree0442fca65fdd47372b176f13ad3bb8b14c078356 /ecomp-sdk
parentf90a9c9f3d13a70cb7c1f1338aa19cbfc33dd7fd (diff)
test case written for layout component
test case written for layout component Issue-ID: PORTAL-813 Change-Id: If783ae282496c320afeb8eb25038f8991f8cee3b 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/layout.component.spec.ts14
1 files changed, 12 insertions, 2 deletions
diff --git a/ecomp-sdk/epsdk-app-overlay/src/main/webapp/ngapp/src/app/layout/layout.component.spec.ts b/ecomp-sdk/epsdk-app-overlay/src/main/webapp/ngapp/src/app/layout/layout.component.spec.ts
index 13d3e34a..6a2bb7ff 100644
--- a/ecomp-sdk/epsdk-app-overlay/src/main/webapp/ngapp/src/app/layout/layout.component.spec.ts
+++ b/ecomp-sdk/epsdk-app-overlay/src/main/webapp/ngapp/src/app/layout/layout.component.spec.ts
@@ -41,6 +41,9 @@ import { TranslateModule } from '@ngx-translate/core';
import { HttpClientTestingModule } from '@angular/common/http/testing';
import { LayoutComponent } from './layout.component';
import { LayoutModule } from './layout.module';
+import { MatDialog, MatDialogModule } from '@angular/material';
+import { Overlay } from '@angular/cdk/overlay';
+import { CookieService } from 'ngx-cookie-service';
describe('LayoutComponent', () => {
let component: LayoutComponent;
@@ -48,13 +51,14 @@ describe('LayoutComponent', () => {
beforeEach( async(() => {
TestBed.configureTestingModule({
- providers:[],
+ providers:[CookieService],
imports: [
+ MatDialogModule,
HttpClientTestingModule,
LayoutModule,
RouterTestingModule,
TranslateModule.forRoot(),
- ]
+ ],
}).compileComponents();
})
);
@@ -68,4 +72,10 @@ describe('LayoutComponent', () => {
it('should create', () => {
expect(component).toBeTruthy();
});
+
+ it('should test receiveCollapsed method',()=>{
+ component.receiveCollapsed(true);
+ expect(component.collapedSideBar).toBe(true);
+ })
+
});