import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { FormsModule } from '@angular/forms'; import { DashboardReportGridComponent } from './dashboard-report-grid.component'; import { CUSTOM_ELEMENTS_SCHEMA, NO_ERRORS_SCHEMA } from '@angular/core'; import { HttpClientTestingModule } from '@angular/common/http/testing'; describe('DashboardReportGridComponent', () => { let component: DashboardReportGridComponent; let fixture: ComponentFixture; beforeEach(async(() => { TestBed.configureTestingModule({ schemas: [CUSTOM_ELEMENTS_SCHEMA, NO_ERRORS_SCHEMA], declarations: [ DashboardReportGridComponent ], imports: [FormsModule, HttpClientTestingModule] }) .compileComponents(); })); beforeEach(() => { fixture = TestBed.createComponent(DashboardReportGridComponent); component = fixture.componentInstance; fixture.detectChanges(); }); it('should create', () => { expect(component).toBeTruthy(); }); it('should test ngOnInit method', () => { component.ngOnInit(); }); it('should test changedOption method', () => { component.changedOptions(); }); it('should test assignCopy method', () => { component.assignCopy(); }); it('should test filterItem method', () => { component.filterItem(1); }); it('should test addItem method', () => { component.addItem(); }); });