Coder Social home page Coder Social logo

ashlabs / blanket Goto Github PK

View Code? Open in Web Editor NEW

This project forked from alex-seville/blanket

0.0 2.0 0.0 2.95 MB

blanket.js is a simple code coverage library for javascript. Designed to be easy to install and use, for both browser and nodejs.

Home Page: http://blanketjs.org

License: MIT License

blanket's Introduction

Blanket.js

A seamless JavaScript code coverage library.

Project home page
Blanket_js on Twitter for updates and news.

NOTE: All Pull-Requests must be made into the development branch.

Build Status

NOTE: Blanket.js will throw XHR cross domain errors if run with the file:// protocol. See Special Features Guide for more details and workarounds.

Getting Started

Please see the following guides for using Blanket.js:

Browser

Node

Philosophy

Blanket.js is a code coverage tool for javascript that aims to be:

  1. Easy to install
  2. Easy to use
  3. Easy to understand

Blanket.js can be run seamlessly or can be customized for your needs.

Mechanism

JavaScript code coverage compliments your existing JavaScript tests by adding code coverage statistics (which lines of your source code are covered by your tests).

Blanket works in a 3 step process:

  1. Loading your source files using a modified RequireJS/Require script
  2. Parsing the code using Esprima and node-falafel, and instrumenting the file by adding code tracking lines.
  3. Connecting to hooks in the test runner to output the coverage details after the tests have completed.

Grunt-blanket

A Grunt plugin has been created to allow you to use Blanket like a "traditional" code coverage tool (creating instrumented copies of physical files, as opposed to live-instrumenting). The plugin runs as a standlone project and can be found here.

Compatibility and Features List

See the Compatiblity and Feature List including links to working examples.

Roll your own

  1. git clone [email protected]:alex-seville/blanket.git
  2. npm install
  3. Add your custom build details to the grunt.js file under concat
  4. grunt buildit

A minified and unminfied copy of the source can be created (see the min task).

Development

All development takes place on the development branch
Your pull request must pass all tests (run npm test to be sure) and respect all existing coverage thresholds

Contact

Feel free to add questions to the Issue tracker, or send them to @blanket_js.

Contributors

Thanks to the many people who have contributed to the project.

And thanks also to: RequireJS, Esprima, node-falafel, Mocha, Qunit.

Roadmap

v1.1.5 - Refactor reporter API.

Revision History

May 1-13 - 1.1.4
Loaded reverting for grunt-blanket, branch tracking reporter fixed, coverage on-the-go (displaying coverage results while a single page is being used).

Apr 28-13 - 1.1.3 YUI support added with custom adapter (and some wrapping code). CompoundJS support appears to be outside the scope of project.

... (see full revision history)

License

Copyright (c) 2012-2013 Alex Seville
Licensed under the MIT license.

blanket's People

Contributors

alex-seville avatar ashwinr avatar dead-horse avatar dervalp avatar fnd avatar geek avatar geekdave avatar hasankhan avatar mohamedmansour avatar morkai avatar msaglietto avatar tmrudick avatar xzyfer avatar

Watchers

 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.