Я получаю сообщение об ошибке при запуске теста npm
Can't bind to 'errorStateMatcher' since it isn't a known property of 'input'. ("dth">
<input matInput placeholder="Product Name" formControlName="prod_name"
[ERROR ->][errorStateMatcher]="matcher">
Файл My Spec выглядит следующим образом
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import { RouterTestingModule } from '@angular/router/testing';
import { ReactiveFormsModule } from '@angular/forms';
import { ProductAddComponent } from './product-add.component';
import { FormControl, FormGroupDirective, FormBuilder, FormGroup, NgForm, Validators } from '@angular/forms';
describe('ProductAddComponent', () => {
let component: ProductAddComponent;
let fixture: ComponentFixture<ProductAddComponent>;
beforeEach(async(() => {
TestBed.configureTestingModule({
imports: [RouterTestingModule, ReactiveFormsModule],
declarations: [ ProductAddComponent ],
schemas: [ CUSTOM_ELEMENTS_SCHEMA ]
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(ProductAddComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});
Как предоставить errorStateMatcher
для тестированияблок