X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=portal-FE-common%2Fsrc%2Fapp%2Fpages%2Ffunctional-menu%2Ffunctional-menu-dialog%2Ffunctional-menu-dialog.component.spec.ts;h=439a2eebf04bcd7019215f7fa7a7d8946a618306;hb=4c6f6a443cb2e6effa995e77d56689c1c2dab4ad;hp=de79b9d834c4e6e012f5605b77733d3197333502;hpb=a03dfa273ef6e196bf65acc54b9357d35eb0ed5e;p=portal.git diff --git a/portal-FE-common/src/app/pages/functional-menu/functional-menu-dialog/functional-menu-dialog.component.spec.ts b/portal-FE-common/src/app/pages/functional-menu/functional-menu-dialog/functional-menu-dialog.component.spec.ts index de79b9d8..439a2eeb 100644 --- a/portal-FE-common/src/app/pages/functional-menu/functional-menu-dialog/functional-menu-dialog.component.spec.ts +++ b/portal-FE-common/src/app/pages/functional-menu/functional-menu-dialog/functional-menu-dialog.component.spec.ts @@ -39,14 +39,22 @@ import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { FunctionalMenuDialogComponent } from './functional-menu-dialog.component'; +import { FormsModule } from '@angular/forms'; +import { NgMaterialModule } from 'src/app/ng-material-module'; +import { HttpClientTestingModule } from '@angular/common/http/testing'; +import { NgbActiveModal } from '@ng-bootstrap/ng-bootstrap'; +import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; describe('FunctionalMenuDialogComponent', () => { let component: FunctionalMenuDialogComponent; let fixture: ComponentFixture; + const nodedata: any = {"parentMenuId":"parentMenuTestId","children":{},"name":"TestName","parent":{"name":"TestParentName"}}; beforeEach(async(() => { TestBed.configureTestingModule({ - declarations: [ FunctionalMenuDialogComponent ] + declarations: [ FunctionalMenuDialogComponent ], + imports:[FormsModule,NgMaterialModule,HttpClientTestingModule,BrowserAnimationsModule], + providers:[NgbActiveModal] }) .compileComponents(); })); @@ -54,6 +62,7 @@ describe('FunctionalMenuDialogComponent', () => { beforeEach(() => { fixture = TestBed.createComponent(FunctionalMenuDialogComponent); component = fixture.componentInstance; + component.nodedata = nodedata; fixture.detectChanges(); });