Socket
Socket
Sign inDemoInstall

karma-bro

Package Overview
Dependencies
Maintainers
1
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

karma-bro

A fast browserify integration for Karma that can easily handle large browserify projects


Version published
Weekly downloads
44
increased by10%
Maintainers
1
Weekly downloads
 
Created
Source

karma-bro

A fast browserify integration for Karma that can easily handle large browserify projects.

Usage

Install the plug-in via npm:

npm install --save-dev karma-bro

Add browserify to your Karma configuration as a framework and configure it via the configs preprocessors entry to bundle all CommonJS via browserify before executing the tests. Optionally use the browserify config entry to configure how the bundle gets created.

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

    frameworks: [ 'browserify' ],

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

    browserify: {
      debug: true,
      transform: [ 'brfs' ]
    }
 });
}
Long Version
module.exports = function(karma) {
  karma.set({

    // include browserify first in used frameworks
    frameworks: [ 'browserify', 'jasmine' ],

    // add all your files here
    files: [
      'test/**/*.js'
    ],

    // add preprocessor to the files that should be
    // processed via browserify
    preprocessors: {
      'test/**/*.js': [ 'browserify' ]
    },

    // see what is going on
    logLevel: 'LOG_DEBUG',

    // use autoWatch=true for quick and easy test re-execution once files change
    autoWatch: true,

    // add additional browserify configurations here such as transforms
    browserify: {
      debug: true,
      transform: [ 'brfs' ]
    }
  });
};

License

MIT

Keywords

FAQs

Package last updated on 29 Apr 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc