arranbartish/angular-cli-seed

View on GitHub
src/app/car/components/add/add.component.spec.ts

Summary

Maintainability
A
0 mins
Test Coverage
import { expect } from 'chai';
import { async, ComponentFixture, TestBed } from '@angular/core/testing';

import { AddComponent } from './add.component';
import { ReactiveFormsModule, FormsModule } from '@angular/forms';

describe('AddComponent', () => {
  let component: AddComponent;
  let fixture: ComponentFixture<AddComponent>;

  beforeEach(async(() => {
    TestBed.configureTestingModule({
      declarations: [AddComponent],
      imports: [FormsModule, ReactiveFormsModule]
    })
      .compileComponents();
  }));

  beforeEach(() => {
    fixture = TestBed.createComponent(AddComponent);
    component = fixture.componentInstance;
    fixture.detectChanges();
  });

  it('will be defined', () => {
    expect(component).to.exist;
  });


  it('will add nothing when form is not filled in', () => {
    expect(component).to.exist;
  });
});