O'Reilly logo

Data Visualization with D3 and AngularJS by Christoph Körner

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

Testing the directive

Testing is a very important and indispensable technique when writing good quality code. It makes sure that developers can test code repeatedly and automatically, for example, after the code was modified or when it runs in a different environment. Therefore, testing makes your code scalable, maintainable, and hopefully bug free.

Often, tests of a software are also seen as a documentation of the code because the tests show the proper usage of the code with all possible arguments and options. Moreover, this documentation is always up-to-date and executable, which is a huge advantage to static documentations.

In general, there exist multiple levels for software tests:

  • Unit tests: It is used to test single encapsulated components ...

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