karma-detect-browsers

Karma runner plugin for detecting all browsers installed on the current system.

npm install karma-detect-browsers
3 downloads in the last day
65 downloads in the last week
408 downloads in the last month

karma-detect-browsers Build Status

Karma runner plugin for detecting all browsers installed on the current system. Adds all found browsers to the browser array in the karma config file.

Installation

The easiest way is to keep karma-detect-browsers as a devDependency in your package.json.

{
  "devDependencies": {
    "karma": "~0.10",
    "karma-detect-browsers": "~0.1"
  }
}

You can simple do it by:

npm install karma-detect-browsers --save-dev

Configuration

// karma.conf.js
module.exports = function(config) {
  config.set({
    frameworks: ['detectBrowsers'],

    // configuration
    detectBrowsers: {
      // enable/disable, default is true
      enabled: true,

      // enable/disable phantomjs support, default is true
      usePhantomJS: true
    },

    plugins: [
      'karma-chrome-launcher',
      'karma-firefox-launcher',
      'karma-ie-launcher',
      'karma-safari-launcher',
      'karma-opera-launcher',
      'karma-phantomjs-launcher',
      'karma-detect-browsers'
    ]
  });
};

Contributing

In lieu of a formal styleguide take care to maintain the existing coding style. Lint and test your code using grunt.

You can preview your changes by running:

grunt demo

Release History

v0.1.2

  • add support for phantomjs, is enabled by default, can be disabled

v0.1.1

  • only override browsers in config when a browser was found by the plugin

v0.1.0

  • first release

Author

Litixsoft GmbH

License

Copyright (C) 2013 Litixsoft GmbH info@litixsoft.de Licensed under the MIT license.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included i all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

npm loves you