JavaScript community news log


Daily JavaScript community news and chat

A RubyFlow-inspired community news site for JavaScript and related technologies.

Anyone can post news to be seen by the community (and maybe selected for JavaScript Weekly!)

Testing HTTP requests in Angular has never been easier

When Angular has finally come out, it was possible to test HTTP requests, but it was a tedious work to set it up properly. Multiple dependencies were needed during the module setup and the faked connections were only available through an Observable object. To make things even harder, no built-in assertions were available for the requests. The Angular team knew these problems, so with Angular 4.3 they introduced a new module called HttpClientModule that intends to replace the existing HttpModule and make usage and testing easier by providing straightforward interfaces.

Post a comment

You can use basic HTML markup (e.g. <a>) or Markdown.

As you are not logged in, you will be
directed via GitHub to signup or sign in