import { TestBed, async } from '@angular/core/testing';
import { RouterTestingModule } from '@angular/router/testing';
import { WidgetComponent } from './widget.component';
describe('WidgetComponent', function () {
    beforeEach(async(function () {
        TestBed.configureTestingModule({
            imports: [
                RouterTestingModule
            ],
            declarations: [
                WidgetComponent
            ],
        }).compileComponents();
    }));
    it('should create the app', async(function () {
        var fixture = TestBed.createComponent(WidgetComponent);
        var app = fixture.debugElement.componentInstance;
        expect(app).toBeTruthy();
    }));
    it("should have as title 'rankit works!'", async(function () {
        var fixture = TestBed.createComponent(WidgetComponent);
        var app = fixture.debugElement.componentInstance;
        expect(app.title).toEqual('rankit works!');
    }));
    it('should render title in a h1 tag', async(function () {
        var fixture = TestBed.createComponent(WidgetComponent);
        fixture.detectChanges();
        var compiled = fixture.debugElement.nativeElement;
        expect(compiled.querySelector('h1').textContent).toContain('rankit works!');
    }));
});
