Project for a working example of Jasmine test running on Karma with Require.js (AMD) modules.
I had hard time finding proper solutions for testing AMD code so here's a setup I ended up doing. PhantomJS2 is used for IndexedDB as it supports it.
Uses Dexie.js as IndexedDB wrapper, also uses jasmine-jquery.
Install node dependencies:
$ npm installRun tests:
use karma plugin for Idea.
Libraries used http://requirejs.org/ http://jasmine.github.io/ https://github.com/dfahlander/Dexie.js/wiki/Dexie https://github.com/karma-runner/karma-phantomjs-launcher