I have a small project with Jasmine specs and I am using Testacular as my test runner. I don\'t understand how I can debug, both the app code or the spec code. When I try to set
My favorite approach to debugging tests with Karma (was Testacular) is to use this plugin:
I start up Karma like this:
karma start karma.conf.js --browsers=Chrome --single-run=false --reporters=kjhtml
This opens Karma in debug mode with a "Debug" button. When you click that, it runs all the tests in a Chrome window and shows the results as they go by. At this point you can use Developer Tools, set breakpoints, step into code etc as normal.
Even better, you can click on a failing test and it will switch to a mode where it only runs that one test. Now you can quickly test and debug that one test without having to wait for all the others to run.
To see this in action, here's a GitHub pull request where I added this library to our project:
https://github.com/edx/edx-ui-toolkit/pull/12