1// Karma configuration 2// Generated on Mon Jul 21 2014 15:27:46 GMT-0700 (PDT) 3 4module.exports = function(config) { 5 config.set({ 6 7 // base path that will be used to resolve all patterns (eg. files, exclude) 8 basePath: '.', 9 10 // frameworks to use 11 // available frameworks: https://npmjs.org/browse/keyword/karma-adapter 12 frameworks: ['mocha'], 13 14 // mocha setup 15 client: { 16 mocha: { 17 ui: 'bdd', 18 checkLeaks: true, 19 globals: ['net', 'scrolled', 'oCursor', 'availableWidth', 'topNotUsableSize', 20 'xLabelWidth', 'nblab', 'bottomNotUsableHeightWithoutXLabels', 21 'bottomNotUsableHeightWithXLabels', 'availableHeight', 'clrx', 'clrwidth', 22 'clry', 'clrheight', 'fmtYLabel', 'lgtxt', 'lgtxt2'] 23 }, 24 captureConsole: true 25 }, 26 27 // list of files / patterns to load in the browser 28 files: [ 29 // dependencies 30 'bower_components/platform/platform.js', 31 'test/karma-loader.html', 32 'bower_components/chai/chai.js', 33 'bower_components/sugar/release/sugar-full.development.js', 34 {pattern: 'bower_components/**/*.{js,html,css,map}', included: false}, 35 'node_modules/mocha/mocha.js', 36 // sources 37 'polymer-load-warning.html', 38 {pattern: 'base/*.html', included: false}, 39 {pattern: 'lib/*.html', included: false}, 40 {pattern: 'model/*.html', included: false}, 41 'scripts/*.js', 42 {pattern: 'ui/*.html', included: false}, 43 // tests 44 'lib/test/*.html', 45 'model/test/*.html', 46 'scripts/test/*.html', 47 'ui/test/*', 48 'bower_components/polymer/polymer.html' 49 ], 50 51 // list of files to exclude 52 exclude: [ 53 ], 54 55 // preprocess matching files before serving them to the browser 56 // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor 57 preprocessors: { 58 }, 59 60 // test results reporter to use 61 // possible values: 'dots', 'progress' 62 // available reporters: https://npmjs.org/browse/keyword/karma-reporter 63 reporters: ['progress'], 64 65 // web server port 66 port: 9876, 67 68 // enable / disable colors in the output (reporters and logs) 69 colors: true, 70 71 // level of logging 72 // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG 73 logLevel: config.LOG_ERROR, 74 75 // enable / disable watching file and executing tests whenever any file changes 76 autoWatch: true, 77 78 // start these browsers 79 // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher 80 browsers: ['Chrome'], 81 82 // Continuous Integration mode 83 // if true, Karma captures browsers, runs the tests and exits 84 singleRun: false, 85 86 plugins: [ 87 'karma-mocha', 88 'karma-chrome-launcher' 89 ] 90 }); 91}; 92