You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

chocolate-factory

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

chocolate-factory

Repeatedly run mocha test with varied parameters

0.0.3
latest
Source
npmnpm
Version published
Weekly downloads
5
-16.67%
Maintainers
1
Weekly downloads
 
Created
Source

chocolate-factory

Repeatedly run a mocha test with varying parameters.

Example

var testAll = require('chocolate-factory'),
    thingsToTest = [{
      description: 'should return bar with argument foo'
      argument: 'foo'
      returnValue: 'bar'
    }];

 testAll(thingsToTest).with(function(testDepiction) {
   baz(testDepiction.argument).should.eql(testDepiction.returnValue);
 });

Notes

  • test depictions must have a description parameter
  • test functions must have testDepicition as their first parameter
  • test functions with two parameters will have mocha's done put into the second parameter
  • only the mocha bdd interface is supported

TODO

  • Support something other than bdd interface

FAQs

Package last updated on 20 Aug 2013

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