linemanjs / lineman-angular-template

A Lineman Application Template using AngularJS
251 stars 88 forks source link

Update README.md #27

Closed theotherzach closed 10 years ago

Foxandxss commented 10 years ago

nodemon seems interesting, but I have been told that e2e tests runs just once because they are expensive to run every time.

searls commented 10 years ago

tbh, I'm +meh on this because I want to get us off protractor (it's just way too buggy, we still can't get phantomjs to work on all but one of ten machines). Part of my goal of looking into webdriver alternatives is to get us and clients off protractor.

Foxandxss commented 10 years ago

I don't agree removing protractor. Protractor is the only way to do e2e on angular, if you remove it that won't be any good. Imho /cc @searls

searls commented 10 years ago

Absolutely anything that can drive a browser can be used to write integration tests of Angular applications. I've always been uncomfortable with the coupling of integration test code to app implementation details (namely angular bindings) in Protractor, because it means that your end-to-end test is married to your implementation and can fail due to nothing other than internal, non-user-meaningful changes to the source.

Even more importantly, I can't find anyone for whom protractor works consistently. I know one person who can make it work on Mountain Lion with Chrome, I know zero people who are ever able to get it to work under PhantomJS consistently. Additionally, the selenium-webdriver module on which protractor depends is an absolute trainwreck because of how they tried to mitigate the fact that all HTTP requests under Node.js must be asynchronous by trying to add synchronizing state managers to the WebDriver API, which results in a confused mess of synchronous behavior without meaingful return values.

searls commented 10 years ago

As for why I'd argue that protractor's coupling to Angular is a bad thing, I've written about this before in my comparison of "remote full-stack tests" versus "local full-stack tests"

Foxandxss commented 10 years ago

Works good for me on ML, you need to update chrome webdriver to 0.6+

Protractor comes with a lot of helpers to test angular apps.

Anyway, if you drop support of protractor, I will just fork and maintain it :)

searls commented 10 years ago

Regardless, I would encourage you to develop a separate lineman-protractor plugin that's divorced from the template proper. That way anyone could pull in lineman-angular and then either lineman-protractor or lineman-some-other-webdriver-thing and have their application preconfigured gracefully. Forking a template project would probably mostly serve to confuse noobs and make maintenance a headache as we try to keep them otherwise in sync.

Foxandxss commented 10 years ago

That is way a better solution indeed.