Merge pull request #8372 from monishdeb/CRM-18519
[civicrm-core.git] / karma.conf.js
1 module.exports = function(config) {
2 config.set({
3 autoWatch: true,
4 browsers: ['PhantomJS', 'PhantomJS_custom'],
5 customLaunchers: {
6 'PhantomJS_custom': {
7 base: 'PhantomJS',
8 options: {
9 windowName: 'my-window',
10 settings: {
11 webSecurityEnabled: false
12 }
13 }
14 }
15 },
16 exclude: [
17 ],
18 files: [
19 'bower_components/jquery/dist/jquery.min.js',
20 'bower_components/jquery-ui/jquery-ui.min.js',
21 'bower_components/lodash-compat/lodash.min.js',
22 'bower_components/select2/select2.min.js',
23 'packages/jquery/plugins/jquery.blockUI.js',
24 'bower_components/jquery-validation/dist/jquery.validate.min.js',
25 'packages/jquery/plugins/jquery.timeentry.js',
26 'js/Common.js',
27 'bower_components/angular/angular.js',
28 'bower_components/angular-file-upload/angular-file-upload.js',
29 'bower_components/angular-jquery-dialog-service/dialog-service.js',
30 'bower_components/angular-route/angular-route.js',
31 'bower_components/angular-mocks/angular-mocks.js',
32 'bower_components/angular-ui-sortable/sortable.js',
33 'bower_components/angular-ui-utils/ui-utils.js',
34 'bower_components/angular-unsavedChanges/dist/unsavedChanges.js',
35 'tests/karma/modules.js',
36 'js/crm.ajax.js',
37 'ang/*.js',
38 'ang/**/*.js',
39 'tests/karma/lib/*.js',
40 'tests/karma/**/*.js',
41 'ang/**/*.html'
42 ],
43 preprocessors : {
44 'ang/**/*.html' : ['ng-html2js']
45 },
46
47 ngHtml2JsPreprocessor: {
48 stripPrefix: 'ang/',
49 prependPrefix: '~/',
50 moduleName: 'crmResource'
51 },
52 frameworks: ['jasmine'],
53 logLevel: config.LOG_INFO,
54 port: 9876,
55 reporters: ['progress'],
56 junitReporter: {
57 outputFile: 'tests/output/karma.xml',
58 suite: ''
59 },
60 singleRun: false
61 });
62 };