Creating a Karma compliant test harness for the browser

15 views
Skip to first unread message

Alexander Mills

unread,
Oct 21, 2017, 5:52:04 PM10/21/17
to karma-users
Hey all 

I put this issue on the Karma issue tracker

but I think this topic is better for this Google Group.

I am writing an improved test runner, primarily for backend testing, but from the beginning it was designed to also run in the browser.
I can get it running in the browser with Webpack.

Anyway, it looks like what I need to do is something similar to these:


so I would have to write:


does anyone have any advice or feedback on this?
Would Karma accept a new adaptor repo for Suman?

Thanks
-alex

Alexander Mills

unread,
Oct 21, 2017, 6:00:04 PM10/21/17
to karma-users
A practical up-front question:

In the karma.conf.js file for a new Angular2 project, I see:

frameworks: ['jasmine', '@angular/cli'],   // A
plugins: [
require('karma-jasmine'), // B
require('karma-chrome-launcher'),
require('karma-jasmine-html-reporter'),
require('karma-coverage-istanbul-reporter'),
require('@angular/cli/plugins/karma')
],

what is the difference between using  'jasmine' on line A
and using 'karma-jasmine' on line B?

-alex

Alexander Mills

unread,
Oct 21, 2017, 8:44:35 PM10/21/17
to karma-users
Ok I have made some progress on this - one thing I don't understand is how Karma knows that the tests are complete and how it knows whether the process should exit with code 0 or not.
Reply all
Reply to author
Forward
0 new messages