Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Testing Angular.js (rockyj.in)
7 points by rockyj on Aug 3, 2013 | hide | past | favorite | 1 comment


The problem with this kind of article is they are too trivial to be truly original and don't help testing a real application, even a light one. Who want to test his evening project ?

Worst, it's by far too light on karma and E2E testing. They have a lot of pitfalls, traps, and documentation is nearly inexistent. A shame considering the size of these projects.

I upvoted, though, because I want more discussion on that topic.

For anyone who want further links about Unit-testing on Angular, I recommend the series from Benjamin Lesh on testing controllers[1], services[2], and directives[3].

This article[4] from The Year of Moo is also excellent and introduces the limit of End-to-end testing with a solution.

[1]: http://www.benlesh.com/2013/05/angularjs-unit-testing-contro...

[2]: http://www.benlesh.com/2013/06/angular-js-unit-testing-servi...

[3]: http://www.benlesh.com/2013/06/angular-js-unit-testing-direc...

[4]: http://www.yearofmoo.com/2013/01/full-spectrum-testing-with-...

I'll be highly interested if someone has anything consistent about Karma and Angular-scenario. I didn't find anything satisfactory about setup anything bigger than 200 LoC. For what I saw, people run away from Angular-scenario and inject Jasmine and Mocks as a work-around.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: