karma.conf.js

Reading time ~1 minute

To configure Karma, the test runner, there are karma.conf.js and karma-test-shim.js.

karma.conf.js

First, the ‘framework’ is set to Jasmine. Then karma-jasmine, karma-chrome-launcher, and karma-htmlfile-reporter are set as required plugins and ‘customLaunchers’ is set to launch the Chrome browser.

Next there is a big block that tells which files are to be sent to the browser and which are to be served by the Karma webserver.

The next interesting configuration is for the reporters which is set to ‘progress’ and also ‘html’ which is configured in the next block and is set to output a tests.html file at the end of the test run.

Lastly, some miscellaneous items like the the port, colors (for reporters and logs), logLevel, autoWatch (for automatically running the tests if a file changes, the browser (Chrome), and singleRun which tells Karma to run the tests once and then exit (false).

How Do I Document?

I don't have an answer to the question. I'm just riffing here. Trying to figure out how to create value for a yet to be determined audien...… Continue reading

Alexa Skill - Part 4

Published on September 19, 2018

Alexa Skill - Part 3

Published on September 16, 2018