Wednesday, August 13, 2014

Webstorm can run the unit tests and even let you debug them interactively. Although the debugger isn't nearly as nice as Chrome's, it's still a bit easier since you can edit your source code quickly and then re-run the test.

Step 1 - Enable Karma integration for Webstorm

Step 2

Make a copy of Karma.conf.js, (name it .tmp so it is ignored by git) and add a specific version of angular.

Step 3

Add a Karma Run Configuration

and use your new .tmp file as the Configuration file. Mine looks like this:

Step 4

Click the Karma run button and your tests should run. You can change the browser that Karma is using in the .tmp config file. Note that debugging is only supported in Chrome and Firefox at the time of publishing.