import { ComponentFixture , TestBed , inject , waitForAsync } from '@angular/core/testing' ; import { RouterTestingModule } from '@angular/router/testing' ; import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core' ; import { CommonModule } from '@angular/common' ; import { FormsModule } from '@angular/forms' ; import { ActivatedRoute } from '@angular/router' ; import { of } from 'rxjs' ; import { NgbButtonsModule , NgbCollapseModule , NgbTooltipModule } from '@ng-bootstrap/ng-bootstrap' ; import { NavTreeSampleComponent } from './nav-tree-sample.component' ; import { ObNavTreeComponent , ObliqueTestingModule } from '@oblique/oblique' ; describe ( 'ObNavTreeSampleComponent' , ( ) => { let component ; let fixture ; beforeEach ( waitForAsync ( ( ) => { TestBed . configureTestingModule ( { declarations : [ NavTreeSampleComponent , ObNavTreeComponent ] , imports : [ CommonModule , FormsModule , RouterTestingModule , NgbCollapseModule , NgbButtonsModule , NgbTooltipModule , ObliqueTestingModule ] , schemas : [ CUSTOM_ELEMENTS_SCHEMA ] } ) . compileComponents ( ) ; } ) ) ; beforeEach ( inject ( [ ActivatedRoute ] , ( activatedRoute ) => { activatedRoute . data = of ( { sample : { navTree : { items : [ ] } } } ) ; fixture = TestBed . createComponent ( NavTreeSampleComponent ) ; component = fixture . componentInstance ; fixture . detectChanges ( ) ; } ) ) ; it ( 'should create' , ( ) => { expect ( component ) . toBeTruthy ( ) ; } ) ; } ) ;