Saturday, June 4, 2016

AngularJS application automation with Protractor (Environment Setup)

The popularity of AngularJS is very high and it is increasing more and more. AngularJS is maintained by Google and Protractor till now is the best end-to-end test framework for AngularJS applications. I want to share my experience with Protractor through this blog.

Protractor Websitehttp://www.protractortest.org/

Protractor API Documentationhttp://www.protractortest.org/#/api

Protractor GitHub urlhttps://github.com/angular/protractor

Environment Setup for Protractor

* Java and NodeJS is needed to create the environment. Download and install :

Java http://www.oracle.com/technetwork/java/javase/downloads/index.html

NodeJS http://nodejs.org/

Open terminal and run "node -v" command to check if NodeJS installed properly.

* Install Protractor globally with npm :

 npm install -g protractor  


Now run "protractor --version" to make sure it installed properly. After installing protractor "webdriver-manager" will also be installed. "webdriver-manager" is a helper tool to run Selenium Server. Download necessary binaries of "webdriver-manager" with : 

 webdriver-manager update

Start Selenium server with : 
 webdriver-manager start  

This will start the Selenium server and you can see the server status at http://localhost:4444/wd/hub .

Congrats you have successfully completed the environment setup for Protractor. kudos for your effort :) . Next blog on Protractor will be >> How to create and run test. 

Thanks for your time. Leave any comment and please suggest if i should add or improve anything.

~~ Automation is important but 
Man is still the most extraordinary computer of all.—John F. Kennedy
 :) ~~
 

No comments:

Post a Comment