Top "Karma-runner" questions

Karma provides developers a testing environment where they don't have to set up many things, rather just write code and get instant feedback in order to improve productivity and creativity.

View Karma Test Output in a Browser?

I'm new to Karma, but I'm wondering how to view its output in a browser (much like the way one …

karma-runner
Angular2, testing and resolved data: How to test ngOnInit?

I'm working through the Angular2 testing guide and wish to write a test for the ngOnInit() function. The one from …

javascript angular jasmine karma-runner resolver
Unit-testing directive controllers in Angular without making controller global

In Vojta Jina's excellent repository where he demonstrates testing of directives, he defines the directive controller outside of the module …

unit-testing angularjs angularjs-directive jasmine karma-runner
TypeError: expect(...).to.be is not a function

I am configuring my Karma amd mocha framework with grunt in my project. When I am running karma start I …

javascript karma-runner karma-mocha
Testing Angular component with unsubscribe Error during cleanup of component

I'm testing a component which subscribe router params. Every test pass and everything works fine. But if I look in …

angular typescript karma-runner karma-jasmine
Unable to run Coverage with Karma

I'm trying to run coverage with karma, and I get the warning: WARN [preprocess]: Can not load "coverage", it is …

javascript code-coverage karma-runner
angular 4 unit testing error `TypeError: ctor is not a constructor`

I am trying to test my route resolver and while testing I got TypeError: ctor is not a constructor and …

angular karma-runner angular-routing
debug in browser using testacular (now karma)

I am trying to figure out the best way to debug my unit tests when I break them. Typically in …

angularjs karma-runner
How do I exclude files from karma code coverage report?

Is there a way to exclude files from code coverage report for the karma coverage runner https://github.com/karma-runner/…

karma-runner karma-jasmine karma-coverage
karma start Cannot find module 'jasmine-core'

I was getting the following error when I ran "karma start" module.js:340 throw err; ^ Error: Cannot find module 'jasmine-core' …

module jasmine karma-runner