填写这份《一分钟调查》,帮我们(开发组)做得更好!去填写Home

HttpClientTestingModule

提供配置 HttpClientTestingBackend 作为 HttpBackend 所使用 HttpClient

Configures HttpClientTestingBackend as the HttpBackend used by HttpClient.

查看"说明"...

      
      class HttpClientTestingModule {
}
    

说明

注入 HttpTestingController 以期望并刷新测试中的请求。

Inject HttpTestingController to expect and flush requests in your tests.

提供商

提供商
      
      HttpClientTestingBackend
    
      
      { provide: HttpBackend, useExisting: HttpClientTestingBackend }
    
      
      { provide: HttpTestingController, useExisting: HttpClientTestingBackend }