Protractor is a framework of functional tests for AngularJS applications. It serves as an integrated solution that combines powerful tools and technologies, such as Node.js, Selenium WebDriver, Jasmine, Cucumber, and Mocha.
Tip
You can find more information about Protractor at https://github.com/angular/protractor. Jasmine is also compatible with Protractor because all the resources that are extracted from the browser to perform the tests are promises. Also, the expect()
function of Jasmine internally handles these promises and makes it seem transparent validations tests.
However, the MEAN.JS generator does not have Protractor in its default installation. So, let's add the necessary dependencies to begin the test with this powerful framework. Perform the following steps:
Open your terminal in the root project folder and type the following command:
npm install protractor –save-dev
In the
grunt-protractor-runner
folder, open thenode_modules/protractor/bin...