To use Protractor, one needs to specify the testing framework that he/she 
is going to use, like Jasmine, Mocha, or a custom framework like Cucumber. 
But why does Protractor need that information? Protractor is more like a JS 
wrapper/implementation of the Java Selenium WebDriver jar, along with 
helpful locators for the Angular world. As such, the scope of Protractor is 
supposed to be to receive commands, like start a browser, navigate to a 
URL, enter text, click the button, etc. Just like how WebDriver is able to 
work "out of the box" with any test framework, like JUnit, TestNG, 
Cucumber, JBehave etc., only because it doesn't need to know the framework. 
A call to create a new WebDriver, is where WebDriver starts, and it ends 
when I call driver.quit(). Theoretically, I could write an entire script 
within a Java main method itself!

Instead, Protractor is too focused on browser management, like browser 
startup on launch (even without a single piece of code in the test 
framework), restarting browser between tests, reporting plugins, parallel 
execution etc. In essence, it is trying to integrate concepts (and 
workload) of a test framework without actually being one.

This inevitably leads to the situation where Protractor has to provide 
instructions and guidelines for "adapters" that other framework creators 
need to follow and use, something unheard of in the Java world, to let 
Protractor talk to it, which isn't required in the first place, imho.

We could make the integration with Protractor much much simpler, only if 
Protractor stuck to the basics, and follow a "listen and execute" approach 
of its parent Selenium WebDriver.

Please feel free to let me know if you think my line of reasoning is 
correct, or if I am missing something.

-- 
You received this message because you are subscribed to the Google Groups 
"Angular and AngularJS discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to