Angular 2 unit tests: How to override a single provider in TestBed (for unit tests for a service, not a component, with service dependencies)?
<p>I have:</p>
<pre class="lang-js prettyprint-override"><code>beforeEach(() =&gt; {
   TestBed.configureTestingModule({
        providers: [
            DocumentsLoaderSvc,
           { provide: MgrSvc, useClass: MockMgrSvc },
           { provide: URLLoaderSvc, useClass:  MockURLLoaderSvcWhenData}
        ]
    });
});
</code></pre>
<p>How do I override URLLoaderSvc with another mock, in an &quot;it&quot; case with its own unique requirement? Is there something like TestBed.overrideProvider... Right now, I have each it statement in its own &quot;describe&quot;, with its own beforeEach.</p>