O'Reilly logo

AngularJS Web Application Development Cookbook by Matt Frisbie

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

Incorporating E2E tests and Protractor in Grunt

Out of the box, Yeoman does not integrate Protractor into its test suite; doing so requires manual work. The Grunt Protractor setup is extremely similar to that of Karma, as they both use the Jasmine syntax and *.conf.js files.

Note

This recipe demonstrates the process of installing and configuring Protractor, but much of this can be generalized to incorporate any new package into Grunt.

Getting ready

The following is a checklist of things to do in order to ensure that your test suite will run correctly:

  • Ensure that the grunt-karma extension is installed using the npm install grunt-karma --save-dev command
  • Save yourself the trouble of having to list out all the needed Grunt tasks in your Gruntfile by automatically ...

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