Information below valid as at 14/01/2014.
- Cutting edge technology
- AngularJS developed
- They are using it to replace ngScenario runner (ie – it will be supported in the future)
- Protractor knows it’s an Angular App
- Uses ng features like smart wait/sleeps for angular services (ie – Protractor watches the $http module and automatically adds in sleeps for you while your requests are pending and your page is rendering. So you no longer have to guess how long a request is going to take and then you don’t have to worry about your tests failing because a request took too long).
- Uses ng features such for bindings, repeaters etc… (ie – bindings use partial match search, grab repeated elements by either row or column)
- Uses patched versions of jasmine to negate the use of promises (ie – .then() and done() etc… exclusion of these leads to cleaner test code).
- Allows you to do native event firing – close to actual user simulation you can get.
- Currently has limited support for MOCHA
- Requires Selenium Server (+ Webdriver & Chromedriver)
- Currently requires patch for PhantomJS to work
See a video by Julie Ralph about Protractor: https://www.youtube.com/watch?v=BvAeabvZ61o (skip to 31:00)
View protractor’s syntax in the repo’s e2e tests: https://github.com/angular/protractor/blob/master/spec/basic/findelements_spec.js
- Selenium server is a binary which controls browsers through web driver protocol.
- Using protractor with non-angular apps: https://github.com/angular/protractor/issues/51