Add seed code for sdnr app based on ONF Centennial
[ccsdk/apps.git] / sdnr / wireless-transport / code-Carbon-SR1 / apps / dlux / dlux-web / karma / karma-unit.tpl.js
diff --git a/sdnr/wireless-transport/code-Carbon-SR1/apps/dlux/dlux-web/karma/karma-unit.tpl.js b/sdnr/wireless-transport/code-Carbon-SR1/apps/dlux/dlux-web/karma/karma-unit.tpl.js
new file mode 100644 (file)
index 0000000..3e2142e
--- /dev/null
@@ -0,0 +1,63 @@
+module.exports = function ( karma ) {
+  karma.set({
+    /** 
+     * From where to look for files, starting with the location of this file.
+     */
+    basePath: '../',
+
+    /**
+     * This is the list of file patterns to load into the browser during testing.
+     */
+    files: [
+     'src/test-main.js',
+     {pattern: 'vendor/**/*.js', included: false},
+     {pattern: 'src/**/*.js', included: false},
+     {pattern: 'src/**/*.js', included: false}
+    ],
+    exclude: [
+      'src/assets/**/*.js'
+    ],
+    frameworks: [ 'jasmine', 'requirejs' ],
+    plugins: [ 'karma-jasmine', 'karma-coverage', 'karma-requirejs', 'karma-firefox-launcher', 'karma-chrome-launcher', 'karma-phantomjs-launcher', 'karma-coffee-preprocessor' ],
+
+    preprocessors: {
+      '**/*.coffee': 'coffee',
+    },
+
+    /**
+     * How to report, by default.
+     */
+    reporters: 'dots',
+
+    /**
+     * On which port should the browser connect, on which port is the test runner
+     * operating, and what is the URL path for the browser to use.
+     */
+    port: 9018,
+    runnerPort: 9101,
+    urlRoot: '/',
+
+    /** 
+     * Disable file watching by default.
+     */
+    autoWatch: false,
+    singleRun: false,
+    /**
+     * The list of browsers to launch to test on. This includes only "Firefox" by
+     * default, but other browser names include:
+     * Chrome, ChromeCanary, Firefox, Opera, Safari, PhantomJS
+     *
+     * Note that you can also use the executable name of the browser, like "chromium"
+     * or "firefox", but that these vary based on your operating system.
+     *
+     * You may also leave this blank and manually navigate your browser to
+     * http://localhost:9018/ when you're running tests. The window/tab can be left
+     * open and the tests will automatically occur there during the build. This has
+     * the aesthetic advantage of not launching a browser every time you save.
+     */
+    browsers: [
+      'Chrome'
+    ]
+  });
+};
+