I\'m developing a github repository (with angular 7 and angular-cli), and I have some tests with Karma and Jasmine working in the master branch.
Now I\'m trying to add l
You passed HeroDetailComponent
to TestBed.createComponent()
without declaring the component first:
TestBed.configureTestingModule({
imports: [AppModule,
CommonModule,
FormsModule,
SharedModule,
HeroRoutingModule,
ReactiveFormsModule
],
providers: [
{provide: APP_BASE_HREF, useValue: '/'}
],
declarations: [HeroDetailComponent]
}).compileComponents();
Hope it helps.
Update for following errors in your test: Added some more imports (just take your HeroModule as a blueprint because that's basically what you want to import and provide).