Open hmil opened 3 years ago
ng-vacuum does not automatically mock local providers. If you wish to mock them, you must manually do so using angular's TestBed
:
import { getMock } from 'ng-vacuum';
import { instance } from 'omnimock';
beforeEach(() => {
TestBed.overrideProvider(MyService, { useValue: instance(getMock(MyService)) });
});
How to mock a local provider declared in a component?