O'Reilly logo

Learning Yeoman by Jonathan Spratley

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

Angular generator solutions

The most common issue with Angular apps is setting up e2e testing. Well, let's cover setting up Protractor with an Angular app, so we can run e2e tests to verify that the application is functioning as it should.

Protractor e2e testing

Problem: I have an AngularJS app that was created using Yeoman and I want to add Protractor e2e testing to my project. I want to run a Grunt task that will start Protractor and execute my project's e2e test specs.

Solution: In order to properly test your AngularJS application using Protractor, you will need to perform the following steps in this order:

  1. Install protractor using npm.
  2. Install grunt-protractor-runner using npm.
  3. Configure the Grunt task.
  4. Create a Protractor configuration file.

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