elmekiesIsrael elmekiesIsrael - 6 months ago 34
AngularJS Question

Running protractor tests as part of the Maven build process

I have a Maven project and I wan't to change the POM so that when I build the project (Clean + Install), after the compilation part, a set of protractor tests will start (opening selenium and doing several things), and only if the tests pass, the build itself passes.

I can't seem to find something that gives me this kind of functionality. Is is possible? and if so, How do I use it?
We are currently using the 'com.github.eirslett' maven plugin for building and I was wondering if it is possible to add the protractor tests as a stage in this plugin. I can see that it supports unit testing with 'Karma' but not anything related to protractor.

Any help will be much appreciated!! Thanks :)


You can use following maven plugin https://github.com/greengerong/maven-ng-protractor

and you can use it like this