import { async , ComponentFixture , TestBed } from '@angular/core/testing' ; import { BlogListComponent } from './blog-list.component' ; import { BlogService } from 'app/services/blog.service' ; import { HttpModule } from '@angular/http' ; describe ( 'BlogListComponent' , ( ) => { let component ; let fixture ; beforeEach ( async ( ( ) => { TestBed . configureTestingModule ( { providers : [ HttpModule , BlogService ] , declarations : [ BlogListComponent ] } ) . compileComponents ( ) ; } ) ) ; beforeEach ( ( ) => { fixture = TestBed . createComponent ( BlogListComponent ) ; component = fixture . componentInstance ; fixture . detectChanges ( ) ; } ) ; it ( 'should be created' , ( ) => { expect ( component ) . toBeTruthy ( ) ; } ) ; } ) ;