Quantcast
Channel: Oracle Bloggers
Viewing all articles
Browse latest Browse all 19780

Karma: Debugging JavaScript Unit Tests

$
0
0

In NetBeans IDE 8.0, you're able to debug JavaScript unit tests via JS Test Driver. In the upcomingNetBeans IDE 8.0.1, JavaScript unit test debugging has been extended to include Karma, as well.

Right-click an HTML5 project and, when you select Karma in the JavaScript Testing tab, you can enable debugging, as shown below. (The new Karma Istanbul code coverage integration was discussed in this blog yesterday.) 

As you can see below, the drop-down lets you choose on which device you want to debug your unit tests:

Then, on the Karma node of your project, enable debugging and start Karma:

Then you can follow the steps in "Debugging a JS Unit Test with JS Test Driver" in the NetBeans tutorial Debugging and Testing JavaScript in an HTML5 Application, with the result shown below, click to enlarge the image.


Viewing all articles
Browse latest Browse all 19780

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>