Hi! Currently in the process of refactoring a good sized AngularJS+ES5 app, with 1000+ karma unit tests to typescript. Started to think about all the issues I had wiring karma tests in the past. Things like test suites breaking because I added a new module dependency, then the service I'm testing is not even using that new dependency...
Then I begin to wonder, why even use Karma for unit testing beyond, perhaps, a thin layer of DI testing. In a unit test all dependencies should be mocked anyway, so why don't I save myself a lot of trouble, and just test directly the es6 exported classes using something like mocha+chai. Abstracting the underlying technology should even help keep things clean? If I have concerns about the DI side I could always add a thin layer to make sure the angular service is really giving me the instance/type I am expecting. Maybe I am too simple minded to see the issues with this... but before I go down this road of all but ditching karma completely though, I thought I might ping you experts to see what you thought. Appreciate any thoughts! /Brian -- 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.
