Giter VIP home page Giter VIP logo

mocaccino.js's Introduction

mocaccino

Build Status SemVer License

Mocha test runner as a Browserify plugin.

Repository: https://github.com/mantoni/mocaccino.js


Install with npm

npm install mocaccino -g

Usage

Mocaccino is a browserify plugin:

browserify -p [ mocaccino OPTIONS ]

where OPTIONS are:

  --reporter, -R  Mocha reporter to use, defaults to "tap"
  --timeout, -t   Mocha timeout in milliseconds to use, defaults to 2000
  --ui, -U        Mocha user interface to use, defaults to "bdd"
  --yields, -y    Yield every N milliseconds, defaults to 250
  --node          If result is used in node instead of a browser

The yields option causes a tiny delay every N milliseconds to allow pending I/O to happen. It's ignored if --node is given.

Headless browser testing

Browserify a test and run in a Phantom.JS with Phantomic:

$ browserify -p mocaccino test.js | phantomic --brout

Code coverage with headless browser

Use the Coverify transform and Phantomic:

$ browserify -p mocaccino -t coverify test.js | phantomic --brout | coverify

Code coverage with node

Use the Coverify transform and node:

$ browserify --bare -p [ mocaccino --node ] -t coverify test.js | node | coverify

Compatibility

  • Node 0.10 or later
  • Browserify 5.9 or later (since version 1.0.0)
  • Browserify 4.x (before 1.0.0)

License

MIT

mocaccino.js's People

Contributors

mantoni avatar jprichardson avatar andreypopp avatar glassresistor avatar

Watchers

James Cloos avatar onceknown avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.