O'Reilly logo

Angular Test-Driven Development - Second Edition by Md. Ziaul Haq

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Using Karma with Angular

Here, we will walk through a TDD approach to an Angular component. By the end of this chapter, we should be able to do the following:

  • Feel confident about using Karma and its configuration
  • Understand the basic components of a Jasmine test
  • Start understanding the integration of a TDD approach in an Angular application

Getting Angular

Angular installation is not possible via Bower; as it was with Angular1, it has to be installed via npm. Bootstrapping the Angular application is not as simple as Angular1 because Angular doesn't use plain JavaScript. It uses TypeScript or ES6 (ES2015), both of which need to be compiled to plain JavaScript before running them.

We believe that most of the developer are already aware of the Angular ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required