<commit_before>// Karma configuration
// Generated on Wed Dec 09 2015 16:06:35 GMT+0100 (CET)

module.exports = function (config)
{
    config.set({

        // base path, that will be used to resolve files and exclude
        basePath: '',

        // frameworks to use
        frameworks: ['jasmine'],

        // list of files / patterns to load in the browser
        files: [
            'test/main.js'
        ],

        // add a preprocessor for the main test file
        preprocessors: {
            'test/main.js': ['rollup']
        },

        // specify the config for the rollup pre-processor: run babel plugin on the code
        rollupPreprocessor: {
            plugins: [
                require('rollup-plugin-babel')({
                    presets: [
                        require('babel-preset-es2015-rollup')
                    ]
                })
            ]
        },

        // load necessary plugins
        plugins: [
            'karma-jasmine',
            'karma-phantomjs-launcher',
            require('./lib')
        ],

        // list of files to exclude
        exclude: [],

        // test results reporter to use
        // possible values: 'dots', 'progress', 'junit', 'growl', 'coverage'
        reporters: ['progress'],

        // web server port
        port: 9876,

        // enable / disable colors in the output (reporters and logs)
        colors: true,

        // level of logging
        // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO ||
        // config.LOG_DEBUG
        logLevel: config.LOG_INFO,

        // enable / disable watching file and executing tests whenever any file changes
        autoWatch: false,

        // Start these browsers, currently available:
        // - Chrome
        // - ChromeCanary
        // - Firefox
        // - Opera (has to be installed with `npm install karma-opera-launcher`)
        // - Safari (only Mac; has to be installed with `npm install karma-safari-launcher`)
        // - PhantomJS
        // - IE (only Windows; has to be installed with `npm install karma-ie-launcher`)
        browsers: ['PhantomJS'],

        // If browser does not capture in given timeout [ms], kill it
        captureTimeout: 60000,

        // Continuous Integration mode
        // if true, it capture browsers, run tests and exit
        singleRun: true
    });
};
<commit_msg>Use new configuration in test<commit_after>// Karma configuration
// Generated on Wed Dec 09 2015 16:06:35 GMT+0100 (CET)

module.exports = function (config)
{
    config.set({

        // base path, that will be used to resolve files and exclude
        basePath: '',

        // frameworks to use
        frameworks: ['jasmine'],

        // list of files / patterns to load in the browser
        files: [
            'test/main.js'
        ],

        // add a preprocessor for the main test file
        preprocessors: {
            'test/main.js': ['rollup']
        },

        // specify the config for the rollup pre-processor: run babel plugin on the code
        rollupPreprocessor: {
            rollup: {
                plugins: [
                    require('rollup-plugin-babel')({
                        presets: [
                            require('babel-preset-es2015-rollup')
                        ]
                    })
                ]
            }
        },

        // load necessary plugins
        plugins: [
            'karma-jasmine',
            'karma-phantomjs-launcher',
            require('./lib')
        ],

        // list of files to exclude
        exclude: [],

        // test results reporter to use
        // possible values: 'dots', 'progress', 'junit', 'growl', 'coverage'
        reporters: ['progress'],

        // web server port
        port: 9876,

        // enable / disable colors in the output (reporters and logs)
        colors: true,

        // level of logging
        // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO ||
        // config.LOG_DEBUG
        logLevel: config.LOG_INFO,

        // enable / disable watching file and executing tests whenever any file changes
        autoWatch: false,

        // Start these browsers, currently available:
        // - Chrome
        // - ChromeCanary
        // - Firefox
        // - Opera (has to be installed with `npm install karma-opera-launcher`)
        // - Safari (only Mac; has to be installed with `npm install karma-safari-launcher`)
        // - PhantomJS
        // - IE (only Windows; has to be installed with `npm install karma-ie-launcher`)
        browsers: ['PhantomJS'],

        // If browser does not capture in given timeout [ms], kill it
        captureTimeout: 60000,

        // Continuous Integration mode
        // if true, it capture browsers, run tests and exit
        singleRun: true
    });
};
<|endoftext|>


<commit_before>// Karma configuration file
var karma = require('karma');
var ForkTsCheckerWebpackPlugin = require('fork-ts-checker-webpack-plugin');

module.exports = function (karma) {
  var config = {
    singleRun: true,
    autoWatch: false,
    autoWatchInterval: 0,

    // level of logging
    // possible values: LOG_DISABLE, LOG_ERROR, LOG_WARN, LOG_INFO, LOG_DEBUG
    logLevel: "warn",
    // possible values: 'dots', 'progress'
    reporters: 'dots',
    colors: true,

    port: 8080,

    // base path, that will be used to resolve files and exclude
    basePath: '.',

    // Start these browsers, currently available:
    // Chrome, ChromeCanary, Firefox, Opera, Safari, PhantomJS
    browsers: ['ChromeHeadless'],

    frameworks: ['jasmine'],

    plugins: [
      require('karma-chrome-launcher'),
      require('karma-firefox-launcher'),
      require('karma-jasmine'),
      require('karma-sourcemap-loader'),
      require('karma-webpack'),
    ],

    webpack: {
      mode: 'development',

      resolve: {
        extensions: ['.js', '.ts']
      },

      module: {
        rules: [
          {
            test: /\.ts$/,
            loader: 'ts-loader',
            options: {
              configFile: 'test/tsconfig.json',
              transpileOnly: true,
            },
          }
        ]
      },

      plugins: [
        new ForkTsCheckerWebpackPlugin()
      ],
    },

    webpackMiddleware: {
      stats: { chunks: false },
    },

    files: ['test/index.js'],

    preprocessors: {
      'test/index.js': ['webpack', 'sourcemap'],
    },

  };

  karma.set(config);
};
<commit_msg>test(*): update karma chrome headless config https://github.com/travis-ci/docs-travis-ci-com/pull/1671<commit_after>// Karma configuration file
var karma = require('karma');
var ForkTsCheckerWebpackPlugin = require('fork-ts-checker-webpack-plugin');

module.exports = function (karma) {
  var config = {
    singleRun: true,
    autoWatch: false,
    autoWatchInterval: 0,

    // level of logging
    // possible values: LOG_DISABLE, LOG_ERROR, LOG_WARN, LOG_INFO, LOG_DEBUG
    logLevel: "warn",
    // possible values: 'dots', 'progress'
    reporters: 'dots',
    colors: true,

    port: 8080,

    // base path, that will be used to resolve files and exclude
    basePath: '.',

    // Start these browsers, currently available:
    // Chrome, ChromeCanary, Firefox, Opera, Safari, PhantomJS
    browsers: ['ChromeHeadlessNoSandbox'],
    customLaunchers: {
      ChromeHeadlessNoSandbox: { base: 'ChromeHeadless', flags: ['--no-sandbox'] }
    },

    frameworks: ['jasmine'],

    plugins: [
      require('karma-chrome-launcher'),
      require('karma-firefox-launcher'),
      require('karma-jasmine'),
      require('karma-sourcemap-loader'),
      require('karma-webpack'),
    ],

    webpack: {
      mode: 'development',

      resolve: {
        extensions: ['.js', '.ts']
      },

      module: {
        rules: [
          {
            test: /\.ts$/,
            loader: 'ts-loader',
            options: {
              configFile: 'test/tsconfig.json',
              transpileOnly: true,
            },
          }
        ]
      },

      plugins: [
        new ForkTsCheckerWebpackPlugin()
      ],
    },

    webpackMiddleware: {
      stats: { chunks: false },
    },

    files: ['test/index.js'],

    preprocessors: {
      'test/index.js': ['webpack', 'sourcemap'],
    },

  };

  karma.set(config);
};
<|endoftext|>


<commit_before>// Karma configuration
// Generated on Thu Feb 13 2014 16:29:52 GMT+0100 (CET)

module.exports = function (config) {
    'use strict';
    config.set({

        // base path, that will be used to resolve files and exclude
        basePath: '',

        // frameworks to use
        frameworks: ['jasmine', 'requirejs'],

        // list of files / patterns to load in the browser
        files: [
            {pattern: 'src/modules/**/*.js', included: false},
            {pattern: 'test/**/*Spec.js', included: false}, //I don't have any clue why it must be *Spec. TODO: find out.
            {pattern: 'test/fixtures.js', included: false},
            {pattern: 'test/backendMock.js', included: false},
            {pattern: 'test/baseTestSetup.js', included: false},
            {pattern: 'src/app.js', included: false},
            {pattern: 'src/vendor/**/*.js', included: false},
            'test/test-main.js'
        ],

        // list of files to exclude
        exclude: [
        ],

        // test results reporter to use
        // possible values: 'dots', 'progress', 'junit', 'growl', 'coverage'
        reporters: ['progress'],

        // web server port
        port: 9876,

        // enable / disable colors in the output (reporters and logs)
        colors: true,

        // level of logging
        // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
        logLevel: config.LOG_INFO,

        // enable / disable watching file and executing tests whenever any file changes
        autoWatch: true,

        // Start these browsers, currently available:
        // - Chrome
        // - ChromeCanary
        // - Firefox
        // - Opera (has to be installed with `npm install karma-opera-launcher`)
        // - Safari (only Mac; has to be installed with `npm install karma-safari-launcher`)
        // - PhantomJS
        // - IE (only Windows; has to be installed with `npm install karma-ie-launcher`)
        browsers: ['Chrome', 'Firefox'],

        // If browser does not capture in given timeout [ms], kill it
        captureTimeout: 60000,

        // Continuous Integration mode
        // if true, it capture browsers, run tests and exit
        singleRun: false
    });
};
<commit_msg>TRACKR-12 - Support i18n Fixed JS tests<commit_after>// Karma configuration
// Generated on Thu Feb 13 2014 16:29:52 GMT+0100 (CET)

module.exports = function (config) {
    'use strict';
    config.set({

        // base path, that will be used to resolve files and exclude
        basePath: '',

        // frameworks to use
        frameworks: ['jasmine', 'requirejs'],

        // list of files / patterns to load in the browser
        files: [
            {pattern: 'src/modules/**/*.js', included: false},
            {pattern: 'test/**/*Spec.js', included: false}, //I don't have any clue why it must be *Spec. TODO: find out.
            {pattern: 'test/fixtures.js', included: false},
            {pattern: 'test/backendMock.js', included: false},
            {pattern: 'test/baseTestSetup.js', included: false},
            {pattern: 'src/i18n.js', included: false},
            {pattern: 'src/app.js', included: false},
            {pattern: 'src/vendor/**/*.js', included: false},
            'test/test-main.js'
        ],

        // list of files to exclude
        exclude: [
        ],

        // test results reporter to use
        // possible values: 'dots', 'progress', 'junit', 'growl', 'coverage'
        reporters: ['progress'],

        // web server port
        port: 9876,

        // enable / disable colors in the output (reporters and logs)
        colors: true,

        // level of logging
        // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
        logLevel: config.LOG_INFO,

        // enable / disable watching file and executing tests whenever any file changes
        autoWatch: true,

        // Start these browsers, currently available:
        // - Chrome
        // - ChromeCanary
        // - Firefox
        // - Opera (has to be installed with `npm install karma-opera-launcher`)
        // - Safari (only Mac; has to be installed with `npm install karma-safari-launcher`)
        // - PhantomJS
        // - IE (only Windows; has to be installed with `npm install karma-ie-launcher`)
        browsers: ['Chrome', 'Firefox'],

        // If browser does not capture in given timeout [ms], kill it
        captureTimeout: 60000,

        // Continuous Integration mode
        // if true, it capture browsers, run tests and exit
        singleRun: false
    });
};
<|endoftext|>


<commit_before>var snare = {};

snare.setup = function(options) {

    snare.rope = {
        'enabled': false,
        'dev': false,
        'origin': {'x': 0, 'y': 0},
        'id': 'snare-rope',
        'prey': 'snare-prey',
        'css': {
            'position': 'absolute',
            'top': '0px',
            'left': '0px',
            'border': '2px solid #666'
        },
        'update': function(mouseDown, x, y) {
            if(mouseDown) {
               if(this.enabled) {
                   if(x < this.origin.x) {
                       $('#'+this.id).css('left', x).css('width', this.origin.x - x);
                   } else {
                       $('#'+this.id).css('width', x - this.origin.x);
                   }

                   if(y < this.origin.y) {
                       $('#'+this.id).css('top', y).css('height', this.origin.y - y);
                   } else {
                       $('#'+this.id).css('height', y - this.origin.y);
                   }

               } else {
                   this.enabled = true;

                   this.origin.x = x;
                   this.origin.y = y;

                   this.css.top = y + 'px';
                   this.css.left = x + 'px';

                   $('
').appendTo('body').css(this.css);
               }

               this.check(x, y);
            }
        },
        'check': function(x, y) {
            var that = this;

            $('.'+this.prey).each(function() {

                var dims = that.dimensions($('#'+that.id));
                var preyDims = that.dimensions(this);

                if(that.dev) {
                    //console.log('dim: ' + JSON.stringify(dims));
                    //console.log('prey: ' + JSON.stringify(preyDims));
                    $('#snare-dev').html('
selection: '+JSON.stringify(dims)+'
');
                }

                var trapped = false;

                if( that.inside(preyDims.x, preyDims.y, dims.x, dims.y, dims.width, dims.height) )
                    trapped = true;
                if( that.inside(preyDims.x, preyDims.height, dims.x, dims.y, dims.width, dims.height) )
                    trapped = true;
                if( that.inside(preyDims.width, preyDims.y, dims.x, dims.y, dims.width, dims.height) )
                    trapped = true;
                if( that.inside(preyDims.width, preyDims.height, dims.x, dims.y, dims.width, dims.height) )
                    trapped = true;

                if(trapped)
                    $(this).addClass('snare-trapped');
                else
                    $(this).removeClass('snare-trapped');
            });
        },
        'inside': function(x, y, left, top, right, bottom) {
            if(x > left && x < right && y > top && y < bottom)
                return true;
            else
                return false;
        },
        'dimensions': function(el) {
            var pos = $(el).offset();

            var height = parseInt($(el).height());
            var paddedHeight = height + parseInt($(el).css('padding-top')) +
                parseInt($(el).css('padding-bottom'));

            var width = parseInt($(el).width());
            var paddedWidth = width + parseInt($(el).css('padding-left')) +
                parseInt($(el).css('padding-right'));

            return {
                'x': parseInt(pos.left),
                'y': parseInt(pos.top),
                'width': width > paddedWidth ? width : paddedWidth,
                'height': height > paddedHeight ? height : paddedHeight
            };
        },
        'burn': function() {
            $('#'+this.id).remove();
        }
    };

    options = options || {};
    $.extend(snare.rope, options);

    if(options.dev) {
        $('
').appendTo('body').css({'position': 'absolute', 'bottom': '10px'});
    }

    $(document).mouseup(function(e) {
        snare.rope.enabled = false;
        snare.rope.burn();
    });

    $(document).mousemove(function(e) {
           snare.rope.update(e.which === 1, e.pageX, e.pageY);
    });

};
<commit_msg>Simplified the dimensions method<commit_after>var snare = {};

snare.setup = function(options) {

    snare.rope = {
        'enabled': false,
        'dev': false,
        'origin': {'x': 0, 'y': 0},
        'id': 'snare-rope',
        'prey': 'snare-prey',
        'css': {
            'position': 'absolute',
            'top': '0px',
            'left': '0px',
            'border': '2px solid #666'
        },
        'update': function(mouseDown, x, y) {
            if(mouseDown) {
               if(this.enabled) {
                   if(x < this.origin.x) {
                       $('#'+this.id).css('left', x).css('width', this.origin.x - x);
                   } else {
                       $('#'+this.id).css('width', x - this.origin.x);
                   }

                   if(y < this.origin.y) {
                       $('#'+this.id).css('top', y).css('height', this.origin.y - y);
                   } else {
                       $('#'+this.id).css('height', y - this.origin.y);
                   }

               } else {
                   this.enabled = true;

                   this.origin.x = x;
                   this.origin.y = y;

                   this.css.top = y + 'px';
                   this.css.left = x + 'px';

                   $('
').appendTo('body').css(this.css);
               }

               this.check(x, y);
            }
        },
        'check': function(x, y) {
            var that = this;

            $('.'+this.prey).each(function() {

                var dims = that.dims($('#'+that.id));
                var preyDims = that.dims(this);

                if(that.dev) {
                    $('#snare-dev').html('
selection: '+JSON.stringify(dims)+'
');
                }

                var trapped = false;

                if( that.inside(preyDims.x, preyDims.y, dims.x, dims.y, dims.width, dims.height) )
                    trapped = true;
                if( that.inside(preyDims.x, preyDims.height, dims.x, dims.y, dims.width, dims.height) )
                    trapped = true;
                if( that.inside(preyDims.width, preyDims.y, dims.x, dims.y, dims.width, dims.height) )
                    trapped = true;
                if( that.inside(preyDims.width, preyDims.height, dims.x, dims.y, dims.width, dims.height) )
                    trapped = true;

                if(trapped)
                    $(this).addClass('snare-trapped');
                else
                    $(this).removeClass('snare-trapped');
            });
        },
        'inside': function(x, y, left, top, right, bottom) {
            if(x > left && x < right && y > top && y < bottom)
                return true;
            else
                return false;
        },
        'dims': function(el) {
            var pos = $(el).offset();

            return {
                'x': parseInt(pos.left, 10),
                'y': parseInt(pos.top, 10),
                'width': $(el).outerWidth(),
                'height': $(el).outerHeight()
            };
        },
        'burn': function() {
            $('#'+this.id).remove();
        }
    };

    options = options || {};
    $.extend(snare.rope, options);

    if(options.dev) {
        $('
').appendTo('body').css({'position': 'absolute', 'bottom': '10px'});
    }

    $(document).mouseup(function(e) {
        snare.rope.enabled = false;
        snare.rope.burn();
    });

    $(document).mousemove(function(e) {
        snare.rope.update(e.which === 1, e.pageX, e.pageY);
    });

};
<|endoftext|>


<commit_before>var jsonUrl = "demotalks.json";
//var jsonUrl = "../rest/talks";
//var jsonUrl = "http://dev.dukecon.org:9090/talks";
var originHeader = "http://dev.dukecon.org";

function Talk(data, isFavourite) {
    this.id = data.id || '';
    this.day = dukeconDateUtils.getDisplayDate(data.start);
    this.startDisplayed = dukeconDateUtils.getDisplayTime(data.start);
    this.startSortable = data.start || '';
    this.track = data.track || '';
    this.location = data.location || '';
    this.level = data.level || '';
    this.title = data.title || '';
    this.speakers = dukeconUtils.getSpeakerNames(data.speakers);
    this.speakerString = data.speakers ? data.speakers[0].name : ""; // TODO: comma-list
    this.language = data.language || '';
    this.fullAbstract = data.abstractText || '';
    this.shortAbstract = this.fullAbstract.substring(0, 100) + "...";
    this.favourite = ko.observable(isFavourite);
    this.favclass = ko.computed(function() {
        return this.favourite() ? "fa-star" : "fa-star-o";
    }, this);
    this.toggleFavourite = function() {
        this.favourite(!this.favourite());
    };
};

function Speaker(name, company, talks) {
    this.name = name;
    this.company = company;
    this.talks = talks;
};

var dukeconDateUtils = {

    weekDays : ["Sonntag", "Montag", "Dienstag", "Mittwoch", "Donnerstag", "Freitag", "Samstag"],

    getDisplayDate : function(datetimeString) {
        if (!datetimeString) {
            return '';
        }
        var date = new Date(datetimeString);
        var month = this.addTrailingZero(date.getMonth() + 1);
        var day = this.addTrailingZero(date.getDate());
        var weekDay = this.weekDays[date.getDay()];
        return weekDay + ", " + day + "." + month;
    },

    getDisplayTime : function(datetimeString) {
        if (!datetimeString) {
            return '';
        }
        var date = new Date(datetimeString);
        return this.addTrailingZero(date.getHours()) + ":" + this.addTrailingZero(date.getMinutes());
    },

    addTrailingZero : function(data) {
        if (data < 10) {
            return '0' + data;
        }
        return data;
    }
};

//widgets
ko.components.register('header-widget', {
    viewModel : function(params) {
        this.title = params.value;
    },
    template:
        '
'
        + ''
        + '
'
        + 'Talks|Sprecher'
        + '
'
        + '

'
        + '
'
});

ko.components.register('talk-widget', {
    viewModel: function(data) {
        this.talk = data.value;
    },
    template:
        '
'
            + '
'
                + ''
                + ''
            + '
'
            + '

'
            + '
Start:

,
'
            + '
Raum:
'
            + '
Track:
'
            + '
'
});

//not sure where else to put
var dukeconUtils = {
    getSpeakerNames : function(speakers) {
        var filteredSpeakers = _.filter(speakers, function(speaker) {
            return speaker;
        });
        return _.map(filteredSpeakers, function(speaker) {
            return speaker.name + ", " + speaker.company;
        });
    }
};<commit_msg>Added Impressum (required by German law)<commit_after>var jsonUrl = "demotalks.json";
//var jsonUrl = "../rest/talks";
//var jsonUrl = "http://dev.dukecon.org:9090/talks";
var originHeader = "http://dev.dukecon.org";

function Talk(data, isFavourite) {
    this.id = data.id || '';
    this.day = dukeconDateUtils.getDisplayDate(data.start);
    this.startDisplayed = dukeconDateUtils.getDisplayTime(data.start);
    this.startSortable = data.start || '';
    this.track = data.track || '';
    this.location = data.location || '';
    this.level = data.level || '';
    this.title = data.title || '';
    this.speakers = dukeconUtils.getSpeakerNames(data.speakers);
    this.speakerString = data.speakers ? data.speakers[0].name : ""; // TODO: comma-list
    this.language = data.language || '';
    this.fullAbstract = data.abstractText || '';
    this.shortAbstract = this.fullAbstract.substring(0, 100) + "...";
    this.favourite = ko.observable(isFavourite);
    this.favclass = ko.computed(function() {
        return this.favourite() ? "fa-star" : "fa-star-o";
    }, this);
    this.toggleFavourite = function() {
        this.favourite(!this.favourite());
    };
};

function Speaker(name, company, talks) {
    this.name = name;
    this.company = company;
    this.talks = talks;
};

var dukeconDateUtils = {

    weekDays : ["Sonntag", "Montag", "Dienstag", "Mittwoch", "Donnerstag", "Freitag", "Samstag"],

    getDisplayDate : function(datetimeString) {
        if (!datetimeString) {
            return '';
        }
        var date = new Date(datetimeString);
        var month = this.addTrailingZero(date.getMonth() + 1);
        var day = this.addTrailingZero(date.getDate());
        var weekDay = this.weekDays[date.getDay()];
        return weekDay + ", " + day + "." + month;
    },

    getDisplayTime : function(datetimeString) {
        if (!datetimeString) {
            return '';
        }
        var date = new Date(datetimeString);
        return this.addTrailingZero(date.getHours()) + ":" + this.addTrailingZero(date.getMinutes());
    },

    addTrailingZero : function(data) {
        if (data < 10) {
            return '0' + data;
        }
        return data;
    }
};

//widgets
ko.components.register('header-widget', {
    viewModel : function(params) {
        this.title = params.value;
    },
    template:
        '
'
        + ''
        + '
'
        + 'Talks|Sprecher|Impressum'
        + '
'
        + '

'
        + '
'
});

ko.components.register('talk-widget', {
    viewModel: function(data) {
        this.talk = data.value;
    },
    template:
        '
'
            + '
'
                + ''
                + ''
            + '
'
            + '

'
            + '
Start:

,
'
            + '
Raum:
'
            + '
Track:
'
            + '
'
});

//not sure where else to put
var dukeconUtils = {
    getSpeakerNames : function(speakers) {
        var filteredSpeakers = _.filter(speakers, function(speaker) {
            return speaker;
        });
        return _.map(filteredSpeakers, function(speaker) {
            return speaker.name + ", " + speaker.company;
        });
    }
};
<|endoftext|>


<commit_before>// Karma configuration
// Generated on Sat Mar 14 2015 10:03:45 GMT-0400 (EDT)

module.exports = function (config) {
	config.set({

		// base path that will be used to resolve all patterns (eg. files, exclude)
		basePath: '',

		// frameworks to use
		// available frameworks: https://npmjs.org/browse/keyword/karma-adapter
		frameworks: [ 'jasmine', 'browserify' ],

		// list of files / patterns to load in the browser
		files: [
			'test/spec/polyfills.js',
			'css/spark.css',
			'test/**/*.spec.js'
		],

		// list of files to exclude
		exclude: [],

		// preprocess matching files before serving them to the browser
		// available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
		preprocessors: {
			'test/**/*.spec.js': [ 'browserify' ]
		},

		browserify: {
			debug: true,
			plugin: [ [ 'remapify', [
				{
					cwd: './src',
					src: '**/*.js', // glob for the files to remap
					expose: 'spark' // this will expose `__dirname + /client/views/home.js` as `views/home.js`
				}
			] ] ],
			transform: [ 'babelify' ],
			extensions: [ '.js' ]
		},

		// test results reporter to use
		// possible values: 'dots', 'progress'
		// available reporters: https://npmjs.org/browse/keyword/karma-reporter
		reporters: [ 'progress' ],

		// web server port
		port: 9876,

		// enable / disable colors in the output (reporters and logs)
		colors: true,

		// level of logging
		// possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
		logLevel: config.LOG_INFO,

		// enable / disable watching file and executing tests whenever any file changes
		autoWatch: true,

		// start these browsers
		// available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
		browsers: [ 'PhantomJS' ],

		// Continuous Integration mode
		// if true, Karma captures browsers, runs the tests and exits
		singleRun: false
	});
};
<commit_msg>Removed kamra.conf generation info<commit_after>module.exports = function (config) {
	config.set({

		// base path that will be used to resolve all patterns (eg. files, exclude)
		basePath: '',

		// frameworks to use
		// available frameworks: https://npmjs.org/browse/keyword/karma-adapter
		frameworks: [ 'jasmine', 'browserify' ],

		// list of files / patterns to load in the browser
		files: [
			'test/spec/polyfills.js',
			'css/spark.css',
			'test/**/*.spec.js'
		],

		// list of files to exclude
		exclude: [],

		// preprocess matching files before serving them to the browser
		// available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
		preprocessors: {
			'test/**/*.spec.js': [ 'browserify' ]
		},

		browserify: {
			debug: true,
			plugin: [ [ 'remapify', [
				{
					cwd: './src',
					src: '**/*.js', // glob for the files to remap
					expose: 'spark' // this will expose `__dirname + /client/views/home.js` as `views/home.js`
				}
			] ] ],
			transform: [ 'babelify' ],
			extensions: [ '.js' ]
		},

		// test results reporter to use
		// possible values: 'dots', 'progress'
		// available reporters: https://npmjs.org/browse/keyword/karma-reporter
		reporters: [ 'progress' ],

		// web server port
		port: 9876,

		// enable / disable colors in the output (reporters and logs)
		colors: true,

		// level of logging
		// possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
		logLevel: config.LOG_INFO,

		// enable / disable watching file and executing tests whenever any file changes
		autoWatch: true,

		// start these browsers
		// available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
		browsers: [ 'PhantomJS' ],

		// Continuous Integration mode
		// if true, Karma captures browsers, runs the tests and exits
		singleRun: false
	});
};
<|endoftext|>


<commit_before>const path = require('path');

const env = process.env.NODE_ENV || 'development';

const gutil = require('gulp-util');

const sources_base_dir = './sources';
const js_sources_base_dir = path.join(sources_base_dir, 'js')
const output_base_dir = process.env.OUTPUT_BASE_DIR || './build';
const assets_base_dir = path.join(output_base_dir, 'assets');
const env_config = {};

const env_config_file_path = path.resolve('.env');

try {
	gutil.log(`Load ${env} env config`);
	Object.assign(env_config, require(env_config_file_path)[env]);
} catch(err) {
	gutil.log(`Fail to load ${env_config_file_path}`);
	process.exit(1);
}

module.exports = {
	get isDevelopment() {
		return env === 'development' || env === 'test';
	},
	get isProduction() {
		return !this.isDevelopment;
	},
	get sourceBaseDir() {
		return sources_base_dir;
	},
	get jsSourceBaseDir() {
		return js_sources_base_dir;
	},
	get outputBaseDir() {
		return output_base_dir;
	},
	get assetsOutputBaseDir() {
		return assets_base_dir;
	},
	get applets() {
		return {
			get sourcesDir() {
				return path.join(js_sources_base_dir, 'applets');
			},
			get outputDir() {
				return path.join(assets_base_dir, 'js', 'applets');
			},
			prefix(applet) {
				return `/${path.relative(output_base_dir, this.outputDir)}/${applet}.js`.replace(/\\/g, '/');
			}
		};
	},
	get content() {
		return {
			get sourcesBaseDir() {
				return path.join(sources_base_dir, 'content');
			},
			get matterDir() {
				return path.join(this.sourcesBaseDir, 'matter');
			},
			get layoutsDir() {
				return path.join(this.sourcesBaseDir, 'layouts');
			},
			get partialsDir() {
				return path.join(this.sourcesBaseDir, 'partials');
			},
			get helpersDir() {
				return path.join(this.sourcesBaseDir, 'helpers');
			},
			get outputDir() {
				return output_base_dir;
			},
			get metadata() {
				return (env_config.content || {}).metadata;
			}
		};
	},
	sass: {
		get sourcesDir() {
			return path.join(sources_base_dir, 'sass');
		},
		get outputDir(){
			return path.join(assets_base_dir, 'css');
		},
		prefix(resource) {
			return `/${path.relative(output_base_dir, this.outputDir)}/${resource}.css`.replace(/\\/g, '/');
		}
	},
};
<commit_msg>fix env_config_file_path value<commit_after>const path = require('path');

const env = process.env.NODE_ENV || 'development';

const gutil = require('gulp-util');

const sources_base_dir = './sources';
const js_sources_base_dir = path.join(sources_base_dir, 'js')
const output_base_dir = process.env.OUTPUT_BASE_DIR || './build';
const assets_base_dir = path.join(output_base_dir, 'assets');

const env_config_file_path = path.resolve('.env.json');
const env_config = {};

try {
	gutil.log(`Load ${env} env config`);
	Object.assign(env_config, require(env_config_file_path)[env]);
} catch(err) {
	gutil.log(`Fail to load ${env_config_file_path}`);
	process.exit(1);
}

module.exports = {
	get isDevelopment() {
		return env === 'development' || env === 'test';
	},
	get isProduction() {
		return !this.isDevelopment;
	},
	get sourceBaseDir() {
		return sources_base_dir;
	},
	get jsSourceBaseDir() {
		return js_sources_base_dir;
	},
	get outputBaseDir() {
		return output_base_dir;
	},
	get assetsOutputBaseDir() {
		return assets_base_dir;
	},
	get applets() {
		return {
			get sourcesDir() {
				return path.join(js_sources_base_dir, 'applets');
			},
			get outputDir() {
				return path.join(assets_base_dir, 'js', 'applets');
			},
			prefix(applet) {
				return `/${path.relative(output_base_dir, this.outputDir)}/${applet}.js`.replace(/\\/g, '/');
			}
		};
	},
	get content() {
		return {
			get sourcesBaseDir() {
				return path.join(sources_base_dir, 'content');
			},
			get matterDir() {
				return path.join(this.sourcesBaseDir, 'matter');
			},
			get layoutsDir() {
				return path.join(this.sourcesBaseDir, 'layouts');
			},
			get partialsDir() {
				return path.join(this.sourcesBaseDir, 'partials');
			},
			get helpersDir() {
				return path.join(this.sourcesBaseDir, 'helpers');
			},
			get outputDir() {
				return output_base_dir;
			},
			get metadata() {
				return (env_config.content || {}).metadata;
			}
		};
	},
	sass: {
		get sourcesDir() {
			return path.join(sources_base_dir, 'sass');
		},
		get outputDir(){
			return path.join(assets_base_dir, 'css');
		},
		prefix(resource) {
			return `/${path.relative(output_base_dir, this.outputDir)}/${resource}.css`.replace(/\\/g, '/');
		}
	},
};
<|endoftext|>


<commit_before>module.exports = function(config) {
    config.set({

        basePath: '',

        files: [
            'test/vendor/es5-shim.js',
            'test/vendor/jquery-2.1.1.js',
            'test/client/**/*.test.js'
        ],

        frameworks: ['mocha', 'browserify'],

        browserify: {
            debug: true
        },

        preprocessors: {
            'test/browser/**/*.test.js': ['browserify']
        },

        reporters: ['progress'],

        port: 9876,
        colors: true,
        logLevel: config.LOG_INFO,
        autoWatch: false,
        browsers: ['PhantomJS'],
        singleRun: false
    });
};
<commit_msg>fix bug in karma conf due to test restructure.<commit_after>module.exports = function(config) {
    config.set({

        basePath: '',

        files: [
            'test/vendor/es5-shim.js',
            'test/vendor/jquery-2.1.1.js',
            'test/client/**/*.test.js'
        ],

        frameworks: ['mocha', 'browserify'],

        browserify: {
            debug: true
        },

        preprocessors: {
            'test/client/**/*.test.js': ['browserify']
        },

        reporters: ['progress'],

        port: 9876,
        colors: true,
        logLevel: config.LOG_INFO,
        autoWatch: false,
        browsers: ['PhantomJS'],
        singleRun: false
    });
};
<|endoftext|>


<commit_before>// Test function that fetches sample JSON and modifies page to display information for one species
function fetchSpeciesData(name) {
    const URL = '/speciesData?species=' + name;
    fetch(URL).then(response => response.json()).then(speciesData => {
        var commonNameContainer     = document.getElementById('common-name-container');
        var scientificNameContainer = document.getElementById('scientific-name-container');
        var statusContainer         = document.getElementById('status-container');
        var descriptionContainer    = document.getElementById('description-container');
        var citationsContainer      = document.getElementById('citations-container');
        var img                     = document.getElementById('species-image');
        var pixelSlider             = document.getElementById('pixel_factor');
        var kingdomContainer        = document.getElementById('kingdom-container');
        var phylumContainer         = document.getElementById('phylum-container');
        var classContainer          = document.getElementById('class-container');
        var orderContainer          = document.getElementById('order-container');
        var familyContainer         = document.getElementById('family-container');
        var genusContainer          = document.getElementById('genus-container');

        // Update names for species
        commonNameContainer.innerText       = speciesData.commonName;
        scientificNameContainer.innerText   = speciesData.binomialName;

        // Map conservation status code to term and update entry
        var statusCode  = speciesData.status;
        switch(statusCode) {
            case null:
                break;
            default:
                statusCode = statusCode.substring(0, 2);
        }
        var statusMap   = {
                            "EX" : "Extinct",
                            "EW" : "Extinct in the Wild",
                            "CR" : "Critically Endangered",
                            "EN" : "Endangered",
                            "VU" : "Vulnerable",
                            "NT" : "Near Threatened",
                            "LC" : "Least Concern",
                            "DD" : "Data Deficient",
                            "DO" : "Domesticated",
                            "NE" : "Not Evaluated"
                          };
        statusContainer.innerText = statusMap[statusCode] === undefined ? "unknown" : statusCode + ": " + statusMap[statusCode];

        // Update description entry
        var notes = speciesData.wikipediaNotes;
        switch(notes) {
            case null:
                descriptionContainer.innerText = "N/A";
                break;
            case "":
                descriptionContainer.innerText = "N/A";
                break;
            default:
                descriptionContainer.innerText = notes.substr(0, notes.indexOf('['));
        }
        citationsContainer.innerText = speciesData.citationLink;

        // Update image source
        img.src = speciesData.imageLink;

        // Manipulate pixelation value based on species population
        pixelSlider.max = img.width * img.height;
        var pop = speciesData.population;
        switch(true) {
            case (pop == null):
                pop = pixelSlider.max;
                break;
            case (pop.indexOf('–') > 0):
                // Pixelation population is currently set to the lower bound if a range is given.
                pop = pop.substr(0, pop.indexOf('–'));
                break;
            default:
                break;
        }
        pixelSlider.value = pop;

        // Update species taxonomic path
        if (speciesData.taxonomicPath != null) {
            kingdomContainer.innerText      = speciesData.taxonomicPath.kingdom_t;
            phylumContainer.innerText       = speciesData.taxonomicPath.phylum_t;
            classContainer.innerText        = speciesData.taxonomicPath.class_t;
            orderContainer.innerText        = speciesData.taxonomicPath.order_t;
            familyContainer.innerText       = speciesData.taxonomicPath.family_t;
            genusContainer.innerText        = speciesData.taxonomicPath.genus_t;
        }
    });
}
<commit_msg>Minor changes<commit_after>// Test function that fetches sample JSON and modifies page to display information for one species
function fetchSpeciesData(name) {
    const URL = '/speciesData?species=' + name;
    fetch(URL).then(response => response.json()).then(speciesData => {
        var commonNameContainer     = document.getElementById('common-name-container');
        var scientificNameContainer = document.getElementById('scientific-name-container');
        var statusContainer         = document.getElementById('status-container');
        var descriptionContainer    = document.getElementById('description-container');
        var citationsContainer      = document.getElementById('citations-container');
        var img                     = document.getElementById('species-image');
        var pixelSlider             = document.getElementById('pixel_factor');
        var kingdomContainer        = document.getElementById('kingdom-container');
        var phylumContainer         = document.getElementById('phylum-container');
        var classContainer          = document.getElementById('class-container');
        var orderContainer          = document.getElementById('order-container');
        var familyContainer         = document.getElementById('family-container');
        var genusContainer          = document.getElementById('genus-container');

        // Update names for species
        commonNameContainer.innerText       = speciesData.commonName;
        scientificNameContainer.innerText   = speciesData.binomialName;

        // Map conservation status code to term and update entry
        var statusCode  = speciesData.status;
        statusCode      = (statusCode == null) ? null : statusCode.substr(0, 2);
        var statusMap   = {
                            "EX" : "Extinct",
                            "EW" : "Extinct in the Wild",
                            "CR" : "Critically Endangered",
                            "EN" : "Endangered",
                            "VU" : "Vulnerable",
                            "NT" : "Near Threatened",
                            "LC" : "Least Concern",
                            "DD" : "Data Deficient",
                            "DO" : "Domesticated",
                            "NE" : "Not Evaluated"
                          };
        statusContainer.innerText = statusMap[statusCode] === undefined ? "unknown" : statusCode + ": " + statusMap[statusCode];

        // Update description entry
        var notes = speciesData.wikipediaNotes;
        switch(notes) {
            case null:
                descriptionContainer.innerText = "N/A";
                break;
            case "":
                descriptionContainer.innerText = "N/A";
                break;
            default:
                if (notes.indexOf('[') > 0) {
                    descriptionContainer.innerText = notes.substr(0, notes.indexOf('['));
                }
                else {
                    descriptionContainer.innerText = notes;
                }
        }
        citationsContainer.innerText = speciesData.citationLink;

        // Update image source
        img.src = speciesData.imageLink;

        // Manipulate pixelation value based on species population
        pixelSlider.max = img.width * img.height;
        var pop = speciesData.population;
        switch(true) {
            case (pop == null):
                pop = pixelSlider.max;
                break;
            case (pop.indexOf('–') > 0):
                // Pixelation population is set to the lower bound if population range is given (ex: "300–500").
                pop = pop.substr(0, pop.indexOf('–'));
                break;
            default:
                break;
        }
        pixelSlider.value = pop;

        // Update species taxonomic path
        if (speciesData.taxonomicPath != null) {
            kingdomContainer.innerText      = speciesData.taxonomicPath.kingdom_t;
            phylumContainer.innerText       = speciesData.taxonomicPath.phylum_t;
            classContainer.innerText        = speciesData.taxonomicPath.class_t;
            orderContainer.innerText        = speciesData.taxonomicPath.order_t;
            familyContainer.innerText       = speciesData.taxonomicPath.family_t;
            genusContainer.innerText        = speciesData.taxonomicPath.genus_t;
        }
    });
}
<|endoftext|>


<commit_before>var webpackConfig = require('./webpack.config.js');

module.exports = function(config){
    config.set({
        browsers: [
            'ChromeBackground'
        ],
        customLaunchers: {
            ChromeBackground: {
                base: 'Chrome',
                flags: ['--window-size=0,0']
            }
        },
        singleRun: true,
        frameworks: ['mocha'],
        files:[
            'script-loader!jquery/dist/jquery.min.js',
            'script-loader!foundation-sites/dist/js/foundation.min.js',
            'app/tests/**/*.test.jsx'
        ],
        preprocessors:{
            'app/tests/**/*.test.jsx':['webpack','sourcemap']
        },
        reporters: ['mocha'],
        client:{
            mocha:{
                timeout: '5000'
            }
        },
        webpack: webpackConfig,
        webpackServer:{
            noInfo: true
        }
    });
}<commit_msg>Commitando para o Heroku<commit_after>var webpackConfig = require('./webpack.config.js');

module.exports = function(config){
    config.set({
        browsers: [
            'ChromeBackground'
        ],
        customLaunchers: {
            ChromeBackground: {
                base: 'Chrome',
                flags: ['--window-size=0,0']
            }
        },
        singleRun: true,
        frameworks: ['mocha'],
        files:[
            'script-loader!jquery/dist/jquery.min.js',
            'script-loader!foundation-sites/dist/js/foundation.min.js',
            'app/tests/**/*.test.jsx'
        ],
        preprocessors:{
            'app/tests/**/*.test.jsx':['webpack','sourcemap']
        },
        reporters: ['mocha'],
        client:{

            mocha:{
                timeout: '5000'
            }
        },
        webpack: webpackConfig,
        webpackServer:{
            noInfo: true
        }
    });
}<|endoftext|>


<commit_before>// Karma configuration
// http://karma-runner.github.io/0.10/config/configuration-file.html

module.exports = function(config) {
  config.set({
    // base path, that will be used to resolve files and exclude
    basePath: '',

    // testing framework to use (jasmine/mocha/qunit/...)
    frameworks: ['jasmine'],

    // list of files / patterns to load in the browser
    files: [
      'client/bower_components/jquery/dist/jquery.js',
      'client/bower_components/angular/angular.js',
      'client/bower_components/angular-mocks/angular-mocks.js',
      'client/bower_components/angular-resource/angular-resource.js',
      'client/bower_components/angular-cookies/angular-cookies.js',
      'client/bower_components/angular-sanitize/angular-sanitize.js',
      'client/bower_components/angular-route/angular-route.js',
      'client/bower_components/angular-bootstrap/ui-bootstrap-tpls.js',
      'client/bower_components/lodash/dist/lodash.compat.js',
      'client/bower_components/angular-ui-router/release/angular-ui-router.js',
      'client/app/app.js',
      'client/app/app.coffee',
      'client/app/**/*.js',
      'client/app/**/*.coffee',
      'client/components/**/*.js',
      'client/components/**/*.coffee',
      'client/app/**/*.jade',
      'client/components/**/*.jade',
      'client/app/**/*.html',
      'client/components/**/*.html'
    ],

    preprocessors: {
      '**/*.jade': 'ng-jade2js',
      '**/*.html': 'html2js',
      '**/*.coffee': 'coffee',
    },

    ngHtml2JsPreprocessor: {
      stripPrefix: 'client/'
    },

    ngJade2JsPreprocessor: {
      stripPrefix: 'client/'
    },

    // list of files / patterns to exclude
    exclude: [],

    // web server port
    port: 8080,

    // level of logging
    // possible values: LOG_DISABLE || LOG_ERROR || LOG_WARN || LOG_INFO || LOG_DEBUG
    logLevel: config.LOG_INFO,

    // enable / disable watching file and executing tests whenever any file changes
    autoWatch: false,

    // Start these browsers, currently available:
    // - Chrome
    // - ChromeCanary
    // - Firefox
    // - Opera
    // - Safari (only Mac)
    // - PhantomJS
    // - IE (only Windows)
    browsers: ['PhantomJS'],

    // Continuous Integration mode
    // if true, it capture browsers, run tests and exit
    singleRun: false
  });
};
<commit_msg>(bugfix) inject dependencies into karma config for angularfileupload<commit_after>// Karma configuration
// http://karma-runner.github.io/0.10/config/configuration-file.html

module.exports = function(config) {
  config.set({
    // base path, that will be used to resolve files and exclude
    basePath: '',

    // testing framework to use (jasmine/mocha/qunit/...)
    frameworks: ['jasmine'],

    // list of files / patterns to load in the browser
    files: [
      'client/bower_components/jquery/dist/jquery.js',
      'client/bower_components/angular/angular.js',
      'client/bower_components/angular-mocks/angular-mocks.js',
      'client/bower_components/angular-resource/angular-resource.js',
      'client/bower_components/angular-cookies/angular-cookies.js',
      'client/bower_components/angular-sanitize/angular-sanitize.js',
      'client/bower_components/angular-route/angular-route.js',
      'client/bower_components/angular-bootstrap/ui-bootstrap-tpls.js',
      'client/bower_components/lodash/dist/lodash.compat.js',
      'client/bower_components/angular-ui-router/release/angular-ui-router.js',
      'client/bower_components/ng-file-upload/angular-file-upload.js',
      'client/app/app.js',
      'client/app/app.coffee',
      'client/app/**/*.js',
      'client/app/**/*.coffee',
      'client/components/**/*.js',
      'client/components/**/*.coffee',
      'client/app/**/*.jade',
      'client/components/**/*.jade',
      'client/app/**/*.html',
      'client/components/**/*.html'
    ],

    preprocessors: {
      '**/*.jade': 'ng-jade2js',
      '**/*.html': 'html2js',
      '**/*.coffee': 'coffee',
    },

    ngHtml2JsPreprocessor: {
      stripPrefix: 'client/'
    },

    ngJade2JsPreprocessor: {
      stripPrefix: 'client/'
    },

    // list of files / patterns to exclude
    exclude: [],

    // web server port
    port: 8080,

    // level of logging
    // possible values: LOG_DISABLE || LOG_ERROR || LOG_WARN || LOG_INFO || LOG_DEBUG
    logLevel: config.LOG_INFO,

    // enable / disable watching file and executing tests whenever any file changes
    autoWatch: false,

    // Start these browsers, currently available:
    // - Chrome
    // - ChromeCanary
    // - Firefox
    // - Opera
    // - Safari (only Mac)
    // - PhantomJS
    // - IE (only Windows)
    browsers: ['PhantomJS'],

    // Continuous Integration mode
    // if true, it capture browsers, run tests and exit
    singleRun: false
  });
};
<|endoftext|>


<commit_before>/*jshint node:true*/
"use strict";

module.exports = function(config) {
  config.set({

    // base path that will be used to resolve all patterns (eg. files, exclude)
    baseUrl: '',

    // frameworks to use
    // available frameworks: https://npmjs.org/browse/keyword/karma-adapter
    frameworks: ['jasmine', 'requirejs'],

    // list of files / patterns to load in the browser
    files: [
        'Specs/karma-main.js',
        {pattern: 'Source/**/*.js', included: false},
        {pattern: 'Specs/**/*.js', included: false},
        {pattern: 'Specs/Data/**', included: false, served: true},
        {pattern: 'Source/Assets/**', included: false, served: true}
    ],

    proxies: {
      '/Data': '/base/Specs/Data'
    },

    // list of files to exclude
    exclude: [
        //'Specs/Widgets/**/*.js',
        //'Specs/Scene/**/*.js',
        //'Specs/DataSources/**/*.js',
        //'Specs/Renderer/**/*.js'
    ],

    // preprocess matching files before serving them to the browser
    // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
    preprocessors: {
    },

    // test results reporter to use
    // possible values: 'dots', 'progress'
    // available reporters: https://npmjs.org/browse/keyword/karma-reporter
    reporters: ['spec'],
    specReporter: {
      maxLogLines: 10,
      suppressErrorSummary: true,
      suppressFailed: false,
      suppressPassed: true,  // do not print information about passed tests
      suppressSkipped: true  // do not print information about skipped tests
    },

    // web server port
    port: 9876,

    // enable / disable colors in the output (reporters and logs)
    colors: true,

    // level of logging
    // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
    logLevel: config.LOG_INFO,

    // enable / disable watching file and executing tests whenever any file changes
    autoWatch: false,

    // start these browsers
    // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
    browsers: ['Chrome'],

    // Continuous Integration mode
    // if true, Karma captures browsers, runs the tests and exits
    singleRun: false,

    // Concurrency level
    // how many browser should be started simultanous
    concurrency: Infinity
  });
};
<commit_msg>Proxied data files to localhost:8080<commit_after>/*jshint node:true*/
"use strict";

module.exports = function(config) {
  config.set({

    // base path that will be used to resolve all patterns (eg. files, exclude)
    baseUrl: '',

    // frameworks to use
    // available frameworks: https://npmjs.org/browse/keyword/karma-adapter
    frameworks: ['jasmine', 'requirejs'],

    // list of files / patterns to load in the browser
    files: [
        'Specs/karma-main.js',
        {pattern: 'Source/**/*.js', included: false},
        {pattern: 'Specs/**/*.js', included: false},
        {pattern: 'Specs/Data/**', included: false, served: true},
        {pattern: 'Source/Assets/**', included: false, served: true}
    ],

    proxies: {
      '/Data': 'http://localhost:8080/Specs/Data'
    },

    // list of files to exclude
    exclude: [
    ],

    // preprocess matching files before serving them to the browser
    // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
    preprocessors: {
    },

    // test results reporter to use
    // possible values: 'dots', 'progress'
    // available reporters: https://npmjs.org/browse/keyword/karma-reporter
    reporters: ['spec'],
    specReporter: {
      maxLogLines: 10,
      suppressErrorSummary: true,
      suppressFailed: false,
      suppressPassed: true,  // do not print information about passed tests
      suppressSkipped: true  // do not print information about skipped tests
    },

    // web server port
    port: 9876,

    // enable / disable colors in the output (reporters and logs)
    colors: true,

    // level of logging
    // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
    logLevel: config.LOG_INFO,

    // enable / disable watching file and executing tests whenever any file changes
    autoWatch: false,

    // start these browsers
    // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
    browsers: ['Chrome'],

    // Continuous Integration mode
    // if true, Karma captures browsers, runs the tests and exits
    singleRun: false,

    // Concurrency level
    // how many browser should be started simultanous
    concurrency: Infinity
  });
};
<|endoftext|>


<commit_before>/**
 * Created by roy on 15/8/14.
 */
BI.DownListCombo = BI.inherit(BI.Widget, {
    _defaultConfig: function () {
        return BI.extend(BI.DownListCombo.superclass._defaultConfig.apply(this, arguments), {
            baseCls: "bi-multilayer-down-list-combo",
            height: 24,
            items: [],
            adjustLength: 0,
            direction: "bottom",
            trigger: "click",
            container: null,
            stopPropagation: false,
            el: {}
        });
    },

    _init: function () {
        BI.DownListCombo.superclass._init.apply(this, arguments);
        var self = this, o = this.options;
        this.popupview = BI.createWidget({
            type: "bi.multi_layer_down_list_popup",
            items: o.items,
            chooseType: o.chooseType,
            value: o.value
        });

        this.popupview.on(BI.DownListPopup.EVENT_CHANGE, function (value) {
            self.fireEvent(BI.DownListCombo.EVENT_CHANGE, value);
            self.downlistcombo.hideView();
        });

        this.popupview.on(BI.DownListPopup.EVENT_SON_VALUE_CHANGE, function (value, fatherValue) {
            self.fireEvent(BI.DownListCombo.EVENT_SON_VALUE_CHANGE, value, fatherValue);
            self.downlistcombo.hideView();
        });

        this.downlistcombo = BI.createWidget({
            element: this,
            type: "bi.combo",
            trigger: o.trigger,
            isNeedAdjustWidth: false,
            container: o.container,
            adjustLength: o.adjustLength,
            direction: o.direction,
            stopPropagation: o.stopPropagation,
            el: BI.createWidget(o.el, {
                type: "bi.icon_trigger",
                extraCls: o.iconCls ? o.iconCls : "pull-down-font",
                width: o.width,
                height: o.height
            }),
            popup: {
                el: this.popupview,
                stopPropagation: o.stopPropagation,
                maxHeight: 1000
            }
        });

        this.downlistcombo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW, function () {
            self.fireEvent(BI.DownListCombo.EVENT_BEFORE_POPUPVIEW);
        });
    },

    hideView: function () {
        this.downlistcombo.hideView();
    },

    showView: function (e) {
        this.downlistcombo.showView(e);
    },

    populate: function (items) {
        this.popupview.populate(items);
    },

    setValue: function (v) {
        this.popupview.setValue(v);
    },
    getValue: function () {
        return this.popupview.getValue();
    }
});
BI.DownListCombo.EVENT_CHANGE = "EVENT_CHANGE";
BI.DownListCombo.EVENT_SON_VALUE_CHANGE = "EVENT_SON_VALUE_CHANGE";
BI.DownListCombo.EVENT_BEFORE_POPUPVIEW = "EVENT_BEFORE_POPUPVIEW";

BI.shortcut("bi.multi_layer_down_list_combo", BI.DownListCombo);<commit_msg>无jira任务，BI.DownListCombo重名了，改成BI.MultiLayerDownListCombo<commit_after>/**
 * Created by roy on 15/8/14.
 */
BI.MultiLayerDownListCombo = BI.inherit(BI.Widget, {
    _defaultConfig: function () {
        return BI.extend(BI.MultiLayerDownListCombo.superclass._defaultConfig.apply(this, arguments), {
            baseCls: "bi-multilayer-down-list-combo",
            height: 24,
            items: [],
            adjustLength: 0,
            direction: "bottom",
            trigger: "click",
            container: null,
            stopPropagation: false,
            el: {}
        });
    },

    _init: function () {
        BI.MultiLayerDownListCombo.superclass._init.apply(this, arguments);
        var self = this, o = this.options;
        this.popupview = BI.createWidget({
            type: "bi.multi_layer_down_list_popup",
            items: o.items,
            chooseType: o.chooseType,
            value: o.value
        });

        this.popupview.on(BI.MultiLayerDownListPopup.EVENT_CHANGE, function (value) {
            self.fireEvent(BI.MultiLayerDownListCombo.EVENT_CHANGE, value);
            self.downlistcombo.hideView();
        });

        this.popupview.on(BI.MultiLayerDownListPopup.EVENT_SON_VALUE_CHANGE, function (value, fatherValue) {
            self.fireEvent(BI.MultiLayerDownListCombo.EVENT_SON_VALUE_CHANGE, value, fatherValue);
            self.downlistcombo.hideView();
        });

        this.downlistcombo = BI.createWidget({
            element: this,
            type: "bi.combo",
            trigger: o.trigger,
            isNeedAdjustWidth: false,
            container: o.container,
            adjustLength: o.adjustLength,
            direction: o.direction,
            stopPropagation: o.stopPropagation,
            el: BI.createWidget(o.el, {
                type: "bi.icon_trigger",
                extraCls: o.iconCls ? o.iconCls : "pull-down-font",
                width: o.width,
                height: o.height
            }),
            popup: {
                el: this.popupview,
                stopPropagation: o.stopPropagation,
                maxHeight: 1000
            }
        });

        this.downlistcombo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW, function () {
            self.fireEvent(BI.MultiLayerDownListCombo.EVENT_BEFORE_POPUPVIEW);
        });
    },

    hideView: function () {
        this.downlistcombo.hideView();
    },

    showView: function (e) {
        this.downlistcombo.showView(e);
    },

    populate: function (items) {
        this.popupview.populate(items);
    },

    setValue: function (v) {
        this.popupview.setValue(v);
    },
    getValue: function () {
        return this.popupview.getValue();
    }
});
BI.MultiLayerDownListCombo.EVENT_CHANGE = "EVENT_CHANGE";
BI.MultiLayerDownListCombo.EVENT_SON_VALUE_CHANGE = "EVENT_SON_VALUE_CHANGE";
BI.MultiLayerDownListCombo.EVENT_BEFORE_POPUPVIEW = "EVENT_BEFORE_POPUPVIEW";

BI.shortcut("bi.multi_layer_down_list_combo", BI.MultiLayerDownListCombo);<|endoftext|>


<commit_before>// Karma configuration
// Generated on Mon Feb 24 2014 21:49:20 GMT-0500 (EST)

module.exports = function(config) {
  config.set({

    // base path, that will be used to resolve files and exclude
    basePath: '',

    // frameworks to use
    frameworks: [ 'mocha' ],

    // list of files / patterns to load in the browser
    files: [
      'node_modules/chai/chai.js',
      'node_modules/chai-as-promised/lib/chai-as-promised.js',
      // 'node_modules/when/build/when.js',
      'Snoocore-standalone.js',
      'test/*'
    ],

    // list of files to exclude
    exclude: [
      'test/oauth-test.js',
      'test/snoocore-oauth-test.js',
      'test/snoocore-error-test.js'
    ],

    // test results reporter to use
    // possible values: 'dots', 'progress', 'junit', 'growl', 'coverage'
    reporters: [ 'progress' ],

    // web server port
    port: 9876,

    // enable / disable colors in the output (reporters and logs)
    colors: true,

    // level of logging
    // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
    logLevel: config.LOG_INFO,

    // enable / disable watching file and executing tests whenever any file changes
    autoWatch: false,

    // Start these browsers, currently available:
    // - Chrome
    // - ChromeCanary
    // - Firefox
    // - Opera (has to be installed with `npm install karma-opera-launcher`)
    // - Safari (only Mac; has to be installed with `npm install karma-safari-launcher`)
    // - PhantomJS
    // - IE (only Windows; has to be installed with `npm install karma-ie-launcher`)
    browsers: [
      'PhantomJsNoWebSecurity',
      'ChromeNoWebSecutity'
    ],

    customLaunchers: {
      PhantomJsNoWebSecurity: {
        base: 'PhantomJS',
        flags: ['--web-security=false']
      },
      ChromeNoWebSecutity: {
        base: 'Chrome',
        flags: ['--disable-web-security']
      }
    },

    // If browser does not capture in given timeout [ms], kill it
    captureTimeout: 60000,

    // Try to handle funky situations with phantomjs / other browsers
    // timing out
    browserNoActivityTimeout: 60000,

    // Continuous Integration mode
    // if true, it capture browsers, run tests and exit
    singleRun: true

  });
};
<commit_msg>update browser tests to point to new standalone<commit_after>// Karma configuration
// Generated on Mon Feb 24 2014 21:49:20 GMT-0500 (EST)

module.exports = function(config) {
  config.set({

    // base path, that will be used to resolve files and exclude
    basePath: '',

    // frameworks to use
    frameworks: [ 'mocha' ],

    // list of files / patterns to load in the browser
    files: [
      'node_modules/chai/chai.js',
      'node_modules/chai-as-promised/lib/chai-as-promised.js',
      // 'node_modules/when/build/when.js',
      'dist/Snoocore-standalone.js',
      'test/*'
    ],

    // list of files to exclude
    exclude: [
      'test/oauth-test.js',
      'test/snoocore-oauth-test.js',
      'test/snoocore-error-test.js'
    ],

    // test results reporter to use
    // possible values: 'dots', 'progress', 'junit', 'growl', 'coverage'
    reporters: [ 'progress' ],

    // web server port
    port: 9876,

    // enable / disable colors in the output (reporters and logs)
    colors: true,

    // level of logging
    // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
    logLevel: config.LOG_INFO,

    // enable / disable watching file and executing tests whenever any file changes
    autoWatch: false,

    // Start these browsers, currently available:
    // - Chrome
    // - ChromeCanary
    // - Firefox
    // - Opera (has to be installed with `npm install karma-opera-launcher`)
    // - Safari (only Mac; has to be installed with `npm install karma-safari-launcher`)
    // - PhantomJS
    // - IE (only Windows; has to be installed with `npm install karma-ie-launcher`)
    browsers: [
      'PhantomJsNoWebSecurity',
      'ChromeNoWebSecutity'
    ],

    customLaunchers: {
      PhantomJsNoWebSecurity: {
        base: 'PhantomJS',
        flags: ['--web-security=false']
      },
      ChromeNoWebSecutity: {
        base: 'Chrome',
        flags: ['--disable-web-security']
      }
    },

    // If browser does not capture in given timeout [ms], kill it
    captureTimeout: 60000,

    // Try to handle funky situations with phantomjs / other browsers
    // timing out
    browserNoActivityTimeout: 60000,

    // Continuous Integration mode
    // if true, it capture browsers, run tests and exit
    singleRun: true

  });
};
<|endoftext|>


<commit_before>'use strict'

import ifInsideOneSyllablePrefixWithNextConsonant from './../rules/if-inside-one-syllable-prefix-with-next-consonant'
import ifShortPart from './../rules/if-short-part'
import ifVowelsBeforeAndAfter from './../rules/if-vowels-before-and-after'
import ifVowelWithNextKratkaya from './../rules/if-vowel-with-next-kratkaya'
import isConsonantWithNextVowel from './../rules/is-consonant-with-next-vowel'
import isConsonantWithNextLetterSign from './../rules/is-consonant-with-next-letter-sign'
import isDoubleConsonantWithVowels from './../rules/is-double-consonant-with-vowels'

export default function isNeedHyphen(pos, arr) {
    return (
        ifVowelsBeforeAndAfter(pos, arr) && // 117
        !isConsonantWithNextVowel(pos, arr) && // 118.0
        !isConsonantWithNextLetterSign(pos, arr) && // 119.1
        !ifVowelWithNextKratkaya(pos, arr) && // 119.2
        !ifShortPart(pos, arr) && // 119.3
        !ifInsideOneSyllablePrefixWithNextConsonant(pos, arr) && // 119.4
        !isDoubleConsonantWithVowels(pos, arr) // 119.7
    )
}
<commit_msg>isNeedHyphen: fix code style;<commit_after>'use strict'

import ifInsideOneSyllablePrefixWithNextConsonant from './../rules/if-inside-one-syllable-prefix-with-next-consonant'
import ifShortPart from './../rules/if-short-part'
import ifVowelsBeforeAndAfter from './../rules/if-vowels-before-and-after'
import ifVowelWithNextKratkaya from './../rules/if-vowel-with-next-kratkaya'
import isConsonantWithNextVowel from './../rules/is-consonant-with-next-vowel'
import isConsonantWithNextLetterSign from './../rules/is-consonant-with-next-letter-sign'
import isDoubleConsonantWithVowels from './../rules/is-double-consonant-with-vowels'

export default function isNeedHyphen (pos, arr) {
    return (
        ifVowelsBeforeAndAfter(pos, arr) && // 117
        !isConsonantWithNextVowel(pos, arr) && // 118.0
        !isConsonantWithNextLetterSign(pos, arr) && // 119.1
        !ifVowelWithNextKratkaya(pos, arr) && // 119.2
        !ifShortPart(pos, arr) && // 119.3
        !ifInsideOneSyllablePrefixWithNextConsonant(pos, arr) && // 119.4
        !isDoubleConsonantWithVowels(pos, arr) // 119.7
    )
}
<|endoftext|>


<commit_before>// Karma configuration
// http://karma-runner.github.io/0.10/config/configuration-file.html

module.exports = function(config) {
  config.set({
    // base path, that will be used to resolve files and exclude
    basePath: '',

    // testing framework to use (jasmine/mocha/qunit/...)
    frameworks: ['jasmine'],

    // list of files / patterns to load in the browser
    files: [
      'app/bower_components/jquery/dist/jquery.js',
      'app/bower_components/angular/angular.js',
      'app/bower_components/angular-mocks/angular-mocks.js',
      'app/bower_components/angular-resource/angular-resource.js',
      'app/bower_components/angular-cookies/angular-cookies.js',
      'app/bower_components/angular-sanitize/angular-sanitize.js',
      'app/bower_components/angular-route/angular-route.js',
      'app/bower_components/angular-bootstrap/ui-bootstrap-tpls.js',
      'app/scripts/**/**.**.js',
      'app/scripts/*.js',
      'app/scripts/**/*.js',
      'test/client/mock/**/*.js',
      'test/client/spec/**/*.js'
    ],

    // list of files / patterns to exclude
    exclude: [],

    // web server port
    port: 8080,

    // level of logging
    // possible values: LOG_DISABLE || LOG_ERROR || LOG_WARN || LOG_INFO || LOG_DEBUG
    logLevel: config.LOG_INFO,

    // enable / disable watching file and executing tests whenever any file changes
    autoWatch: false,

    // Start these browsers, currently available:
    // - Chrome
    // - ChromeCanary
    // - Firefox
    // - Opera
    // - Safari (only Mac)
    // - PhantomJS
    // - IE (only Windows)
    browsers: ['Chrome'],

    // Continuous Integration mode
    // if true, it capture browsers, run tests and exit
    singleRun: false
  });
};
<commit_msg>loading jquery-file-upload related for tests.<commit_after>// Karma configuration
// http://karma-runner.github.io/0.10/config/configuration-file.html

module.exports = function(config) {
  config.set({
    // base path, that will be used to resolve files and exclude
    basePath: '',

    // testing framework to use (jasmine/mocha/qunit/...)
    frameworks: ['jasmine'],

    // list of files / patterns to load in the browser
    files: [
      'app/bower_components/jquery/dist/jquery.js',
      'app/bower_components/angular/angular.js',
      'app/bower_components/angular-mocks/angular-mocks.js',
      'app/bower_components/angular-resource/angular-resource.js',
      'app/bower_components/angular-cookies/angular-cookies.js',
      'app/bower_components/angular-sanitize/angular-sanitize.js',
      'app/bower_components/angular-route/angular-route.js',
      'app/bower_components/angular-bootstrap/ui-bootstrap-tpls.js',
      // we should lazy load this files !!!
      'app/bower_components/blueimp-load-image/js/load-image.js',
      'app/bower_components/blueimp-load-image/js/load-image-ios.js',
      'app/bower_components/blueimp-load-image/js/load-image-orientation.js',
      'app/bower_components/blueimp-load-image/js/load-image-meta.js',
      'app/bower_components/blueimp-load-image/js/load-image-exif.js',
      'app/bower_components/blueimp-load-image/js/load-image-exif-map.js',
      'app/bower_components/blueimp-canvas-to-blob/js/canvas-to-blob.js',
      'app/bower_components/jquery-file-upload/js/cors/jquery.postmessage-transport.js',
      'app/bower_components/jquery-file-upload/js/cors/jquery.xdr-transport.js',
      'app/bower_components/jquery-file-upload/js/vendor/jquery.ui.widget.js',
      'app/bower_components/jquery-file-upload/js/jquery.fileupload.js',
      'app/bower_components/jquery-file-upload/js/jquery.fileupload-process.js',
      'app/bower_components/jquery-file-upload/js/jquery.fileupload-validate.js',
      'app/bower_components/jquery-file-upload/js/jquery.fileupload-image.js',
      'app/bower_components/jquery-file-upload/js/jquery.fileupload-audio.js',
      'app/bower_components/jquery-file-upload/js/jquery.fileupload-video.js',
      'app/bower_components/jquery-file-upload/js/jquery.fileupload-ui.js',
      'app/bower_components/jquery-file-upload/js/jquery.fileupload-angular.js',
      'app/bower_components/jquery-file-upload/js/jquery.iframe-transport.js',
      //END we should lazy load this files !!!
      'app/scripts/**/**.**.js',
      'app/scripts/*.js',
      'app/scripts/**/*.js',
      'test/client/mock/**/*.js',
      'test/client/spec/**/*.js'
    ],

    // list of files / patterns to exclude
    exclude: [],

    // web server port
    port: 8080,

    // level of logging
    // possible values: LOG_DISABLE || LOG_ERROR || LOG_WARN || LOG_INFO || LOG_DEBUG
    logLevel: config.LOG_INFO,

    // enable / disable watching file and executing tests whenever any file changes
    autoWatch: false,

    // Start these browsers, currently available:
    // - Chrome
    // - ChromeCanary
    // - Firefox
    // - Opera
    // - Safari (only Mac)
    // - PhantomJS
    // - IE (only Windows)
    browsers: ['Chrome'],

    // Continuous Integration mode
    // if true, it capture browsers, run tests and exit
    singleRun: false
  });
};
<|endoftext|>


<commit_before>// Karma configuration for Unit testing

module.exports = function (config) {

    var configuration = {

        // base path that will be used to resolve all patterns (eg. files, exclude)
        basePath: '',

        // frameworks to use
        // available frameworks: https://npmjs.org/browse/keyword/karma-adapter
        frameworks: ['jasmine'],

        plugins: [
            require('karma-jasmine'),
            require('karma-chrome-launcher'),
            require('karma-webpack'),
            require('karma-sourcemap-loader'),
            require('karma-spec-reporter')
        ],

        // list of files / patterns to load in the browser
        files: [
            { pattern: 'spec.bundle.js', watched: false }
        ],

        // list of files to exclude
        exclude: [
        ],

        // preprocess matching files before serving them to the browser
        // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
        preprocessors: {
            'spec.bundle.js': ['webpack']
        },

        // webpack
        webpack: {
            resolve: {
                extensions: ['.ts', '.js']
            },
            module: {
                rules: [
                    {
                        test: /\.ts/,
                        loaders: ['ts-loader'],
                        exclude: /node_modules/
                    }
                ],
                exprContextCritical: false
            },
            performance: { hints: false }
        },

        webpackServer: {
            noInfo: true
        },

        // test results reporter to use
        // possible values: 'dots', 'progress'
        // available reporters: https://npmjs.org/browse/keyword/karma-reporter
        reporters: ['spec'],

        // web server port
        port: 9876,

        // enable / disable colors in the output (reporters and logs)
        colors: true,

        // level of logging
        // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
        logLevel: config.LOG_INFO,

        // enable / disable watching file and executing tests whenever any file changes
        autoWatch: true,

        // start these browsers
        // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
        browsers: ['Chrome'],

        // Continuous Integration mode
        // if true, Karma captures browsers, runs the tests and exits
        singleRun: true

    };

    config.set(configuration);

}
<commit_msg>chore: text config reformate<commit_after>// Karma configuration for Unit testing

module.exports = function (config) {

    var configuration = {

        // base path that will be used to resolve all patterns (eg. files, exclude)
        basePath: '',

        // frameworks to use
        // available frameworks: https://npmjs.org/browse/keyword/karma-adapter
        frameworks: ['jasmine'],

        plugins: [
            require('karma-jasmine'),
            require('karma-chrome-launcher'),
            require('karma-webpack'),
            require('karma-sourcemap-loader'),
            require('karma-spec-reporter')
        ],

        // list of files / patterns to load in the browser
        files: [{
            pattern: 'spec.bundle.js',
            watched: false
        }],

        // list of files to exclude
        exclude: [],

        // preprocess matching files before serving them to the browser
        // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
        preprocessors: {
            'spec.bundle.js': ['webpack']
        },

        // webpack
        webpack: {
            resolve: {
                extensions: ['.ts', '.js']
            },
            module: {
                rules: [{
                    test: /\.ts/,
                    loaders: ['ts-loader'],
                    exclude: /node_modules/
                }],
                exprContextCritical: false
            },
            performance: {
                hints: false
            }
        },

        webpackServer: {
            noInfo: true
        },

        // test results reporter to use
        // possible values: 'dots', 'progress'
        // available reporters: https://npmjs.org/browse/keyword/karma-reporter
        reporters: ['spec'],

        // web server port
        port: 9876,

        // enable / disable colors in the output (reporters and logs)
        colors: true,

        // level of logging
        // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
        logLevel: config.LOG_INFO,

        // enable / disable watching file and executing tests whenever any file changes
        autoWatch: true,

        // start these browsers
        // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
        browsers: ['Chrome'],

        // Continuous Integration mode
        // if true, Karma captures browsers, runs the tests and exits
        singleRun: true
    };
    config.set(configuration);
}<|endoftext|>


<commit_before>module.exports = function(config) {
  const configuration = {
    basePath: '',
    frameworks: ['mocha', 'chai'],
    files: [
      { pattern: 'build/resources/*.wav', included: false, served: true },
      'build/omnitone.min.js',
      'test/test-setup.js',
      'test/*.js'
      // 'test/!(test-hoa-rotator).js'
    ],
    reporters: ['mocha'],
    port: 9876,
    colors: true,
    logLevel: config.LOG_INFO,
    autoWatch: false,
    browsers: ['Chrome'],
    customLaunchers: {
      Chrome_travis_ci: {
        base: 'Chrome',
        flags: ['--no-sandbox']
      }
    },
    singleRun: false,
    concurrency: Infinity
  };

  // For Travis CI.
  if (process.env.TRAVIS) {
    configuration.browsers = ['Chrome_travis_ci'];
  }

  config.set(configuration);
};
<commit_msg>Karma config fix<commit_after>module.exports = function(config) {
  const configuration = {
    basePath: '',
    frameworks: ['mocha', 'chai'],
    files: [
      { pattern: 'build/resources/*.wav', included: false, served: true },
      'build/omnitone.min.js',
      'test/test-setup.js',
      'test/*.js'
    ],
    reporters: ['mocha'],
    port: 9876,
    colors: true,
    logLevel: config.LOG_INFO,
    autoWatch: false,
    browsers: ['Chrome'],
    customLaunchers: {
      Chrome_travis_ci: {
        base: 'Chrome',
        flags: ['--no-sandbox']
      }
    },
    singleRun: true,
    concurrency: Infinity
  };

  // For Travis CI.
  if (process.env.TRAVIS) {
    configuration.browsers = ['Chrome_travis_ci'];
  }

  config.set(configuration);
};
<|endoftext|>


<commit_before>// Karma configuration
// Generated on Sun Jun 12 2016 12:12:53 GMT-0400 (EDT)

module.exports = function(config) {
    config.set({

        // base path that will be used to resolve all patterns (eg. files, exclude)
        basePath: '',

        // frameworks to use
        // available frameworks: https://npmjs.org/browse/keyword/karma-adapter
        frameworks: ['jasmine'],

        // list of files / patterns to load in the browser
        files: [
            'src/**/*.js',
            'test/**/*.js'
        ],

        // list of files to exclude
        exclude: [
            'test/lib/**/*.js'
        ],

        // preprocess matching files before serving them to the browser
        // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
        preprocessors: {
            'src/**/*.js': ['coverage']
        },

        // test results reporter to use
        // possible values: 'dots', 'progress'
        // available reporters: https://npmjs.org/browse/keyword/karma-reporter
        reporters: ['progress', 'coverage', 'coveralls'],

        coverageReporter: {
            type: 'lcov',
            dir: 'coverage/'
        },

        // web server port
        port: 9876,

        // enable / disable colors in the output (reporters and logs)
        colors: true,

        // level of logging
        // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
        logLevel: config.LOG_INFO,

        // enable / disable watching file and executing tests whenever any file changes
        autoWatch: true,

        // start these browsers
        // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
        browsers: ['PhantomJS'],

        // Continuous Integration mode
        // if true, Karma captures browsers, runs the tests and exits
        singleRun: false,

        // Concurrency level
        // how many browser should be started simultaneous
        concurrency: Infinity
    });
};
<commit_msg>Added rule to not exclude jquery when running tests<commit_after>// Karma configuration
// Generated on Sun Jun 12 2016 12:12:53 GMT-0400 (EDT)

module.exports = function(config) {
    config.set({

        // base path that will be used to resolve all patterns (eg. files, exclude)
        basePath: '',

        // frameworks to use
        // available frameworks: https://npmjs.org/browse/keyword/karma-adapter
        frameworks: ['jasmine'],

        // list of files / patterns to load in the browser
        files: [
            'src/**/*.js',
            'test/**/*.js'
        ],

        // list of files to exclude
        exclude: [
	    'test/**/!(jquery-git.min)',
            'test/lib/**/*.js'
        ],

        // preprocess matching files before serving them to the browser
        // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
        preprocessors: {
            'src/**/*.js': ['coverage']
        },

        // test results reporter to use
        // possible values: 'dots', 'progress'
        // available reporters: https://npmjs.org/browse/keyword/karma-reporter
        reporters: ['progress', 'coverage', 'coveralls'],

        coverageReporter: {
            type: 'lcov',
            dir: 'coverage/'
        },

        // web server port
        port: 9876,

        // enable / disable colors in the output (reporters and logs)
        colors: true,

        // level of logging
        // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
        logLevel: config.LOG_INFO,

        // enable / disable watching file and executing tests whenever any file changes
        autoWatch: true,

        // start these browsers
        // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
        browsers: ['PhantomJS'],

        // Continuous Integration mode
        // if true, Karma captures browsers, runs the tests and exits
        singleRun: false,

        // Concurrency level
        // how many browser should be started simultaneous
        concurrency: Infinity
    });
};
<|endoftext|>


<commit_before>var webpack = require('webpack')
var assign = require('lodash/object/assign')
var webpackConfig = require('./webpack.config')
var browsers = require('./browsers')

module.exports = function (config) {
  config.set({
    customLaunchers: browsers,
    browsers: ['Chrome', 'Firefox', 'Safari'],
    frameworks: ['mocha'],
    files: [
      'node_modules/es5-shim/es5-shim.js',
      'node_modules/es5-shim/es5-sham.js',
      'tests.webpack.js'
    ],
    preprocessors: {
      'tests.webpack.js': [ 'webpack', 'sourcemap' ]
    },
    webpack: assign(webpackConfig, {
      devtool: 'inline-source-map'
    }),
    webpackServer: {
      noInfo: true
    },
    coverageReporter: {
      reporters: [
        { type: 'html', subdir: 'html' },
        { type: 'lcovonly', subdir: '.' }
      ]
    },
    reporters: ['mocha']
  })

  if (process.env.USE_CLOUD) {
    // We support multiple node versions in travis.
    // To reduce load on browserstack, we only run tests in one node version.
    var nodeVersion = parseInt(process.version.substr(1), 10)
    var nodeVersionBrowserStack = parseInt(process.env.NODE_VERSION_BROWSERSTACK, 10)
    if (nodeVersion === nodeVersionBrowserStack) {
      config.browsers = Object.keys(browsers)
    } else {
      config.browsers = ['PhantomJS']
    }

    config.browserDisconnectTimeout = 10000
    config.browserDisconnectTolerance = 3
    config.browserNoActivityTimeout = 30000
    config.captureTimeout = 200000

    if (process.env.TRAVIS) {
      var buildLabel = 'TRAVIS #' + process.env.TRAVIS_BUILD_NUMBER + ' (' + process.env.TRAVIS_BUILD_ID + ')'

      config.browserStack = {
        username: process.env.BROWSER_STACK_USERNAME,
        accessKey: process.env.BROWSER_STACK_ACCESS_KEY,
        pollingTimeout: 10000,
        startTunnel: false,
        project: 'jss',
        build: buildLabel,
        name: process.env.TRAVIS_JOB_NUMBER
      }

      config.singleRun = true
    }
    else {
      config.browserStack = {
        username: process.env.BROWSER_STACK_USERNAME,
        accessKey: process.env.BROWSER_STACK_ACCESS_KEY,
        pollingTimeout: 10000,
        startTunnel: true
      }
    }
  }
}
<commit_msg>a try to fix browserstack<commit_after>var webpack = require('webpack')
var assign = require('lodash/object/assign')
var webpackConfig = require('./webpack.config')
var browsers = require('./browsers')

module.exports = function (config) {
  config.set({
    customLaunchers: browsers,
    browsers: ['Chrome', 'Firefox', 'Safari'],
    frameworks: ['mocha'],
    files: [
      'node_modules/es5-shim/es5-shim.js',
      'node_modules/es5-shim/es5-sham.js',
      'tests.webpack.js'
    ],
    preprocessors: {
      'tests.webpack.js': [ 'webpack', 'sourcemap' ]
    },
    webpack: assign(webpackConfig, {
      devtool: 'inline-source-map'
    }),
    webpackServer: {
      noInfo: true
    },
    coverageReporter: {
      reporters: [
        { type: 'html', subdir: 'html' },
        { type: 'lcovonly', subdir: '.' }
      ]
    },
    reporters: ['mocha']
  })

  if (process.env.USE_CLOUD) {
    // We support multiple node versions in travis.
    // To reduce load on browserstack, we only run tests in one node version.
    var nodeVersion = parseInt(process.version.substr(1), 10)
    var nodeVersionBrowserStack = parseInt(process.env.NODE_VERSION_BROWSERSTACK, 10)
    if (nodeVersion === nodeVersionBrowserStack) {
      config.browsers = Object.keys(browsers)
    } else {
      config.browsers = ['PhantomJS']
    }

    config.browserDisconnectTimeout = 10000
    config.browserDisconnectTolerance = 3
    config.browserNoActivityTimeout = 30000
    config.captureTimeout = 200000

    config.browserStack = {
      username: process.env.BROWSER_STACK_USERNAME,
      accessKey: process.env.BROWSER_STACK_ACCESS_KEY,
      pollingTimeout: 10000
    }

    if (process.env.TRAVIS) {
      assign(config.browserStack, {
        build: 'TRAVIS #' + process.env.TRAVIS_BUILD_NUMBER + ' (' + process.env.TRAVIS_BUILD_ID + ')',
        name: process.env.TRAVIS_JOB_NUMBER
      })
    }
  }
}
<|endoftext|>