O'Reilly logo

Web App Testing Using Knockout.JS by Roberto Messora

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

Unit testing automation with Karma (in GulpJS)

In the previous paragraph, we set up a build process the main objective of which is to verify our code quality and create a release version of the source code. At this point, we need to complete this process introducing unit testing.

One of the most important GulpJS plugins is the Karma integration. Karma (http://karma-runner.github.io/) is a testing environment that provides a series of useful features for developers, such as:

  • It runs tests on different kinds of browsers (not only different vendors, but also devices, such as phones and tablets) or using a PhantomJS instance
  • It supports a series of unit testing frameworks, such as Jasmine, QUnit, and Mocha
  • It can be integrated in several development environments, ...

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