{"_id":"mocha-cases","_rev":"132494","name":"mocha-cases","description":"A tiny mocha test case runner. Suited for simple input to output validation tests.","dist-tags":{"latest":"0.3.0"},"maintainers":[{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"}],"time":{"modified":"2021-06-03T11:13:46.000Z","created":"2015-11-22T21:05:48.403Z","0.3.0":"2019-02-21T17:57:11.309Z","0.2.1":"2018-01-23T15:26:05.590Z","0.2.0":"2018-01-13T21:01:20.789Z","0.1.10":"2016-01-07T18:10:36.507Z","0.1.9":"2016-01-07T13:41:10.491Z","0.1.8":"2016-01-06T15:18:28.230Z","0.1.7":"2016-01-06T13:51:03.369Z","0.1.6":"2015-12-23T19:13:47.046Z","0.1.5":"2015-12-15T20:04:55.833Z","0.1.4":"2015-12-07T12:24:04.781Z","0.1.3":"2015-12-03T07:56:16.041Z","0.1.2":"2015-12-03T07:45:32.629Z","0.1.1":"2015-12-02T22:02:23.469Z","0.1.0":"2015-11-22T21:05:48.403Z"},"users":{"amobiz":true},"author":{"name":"Amobiz","email":"amobiz.tw+github@gmail.com","url":"https://github.com/amobiz"},"repository":{"type":"git","url":"git+https://github.com/amobiz/mocha-cases.git"},"versions":{"0.3.0":{"name":"mocha-cases","version":"0.3.0","description":"A tiny mocha test case runner. Suited for simple input to output validation tests.","main":"index.js","scripts":{"lint":"eslint .","test":"mocha index.test.js"},"repository":{"type":"git","url":"git+https://github.com/amobiz/mocha-cases.git"},"keywords":["mocha","test","cases","runner","json"],"author":{"name":"Amobiz","email":"amobiz.tw+github@gmail.com","url":"https://github.com/amobiz"},"contributors":[{"name":"Ivan Sosnin","email":"vansosnin@gmail.com","url":"https://github.com/vansosnin"}],"license":"MIT","bugs":{"url":"https://github.com/amobiz/mocha-cases/issues"},"homepage":"https://github.com/amobiz/mocha-cases#readme","peerDependencies":{"mocha":">=2.0.0"},"devDependencies":{"eslint":"^5.14.1","mocha":"^6.0.0"},"dependencies":{"async-done":"^1.3.1","chai":"^4.2.0"},"gitHead":"ba162dbb55330710a27acc42ad55597d235f31ec","_id":"mocha-cases@0.3.0","_nodeVersion":"8.11.2","_npmVersion":"6.8.0","dist":{"shasum":"af164bcdccf4b576844a43f2e151044f110dbdac","size":4606,"noattachment":false,"key":"/mocha-cases/-/mocha-cases-0.3.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/mocha-cases/download/mocha-cases-0.3.0.tgz"},"maintainers":[{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"}],"_npmUser":{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mocha-cases_0.3.0_1550771831091_0.3032868121534067"},"_hasShrinkwrap":false,"publish_time":1550771831309,"_cnpm_publish_time":1550771831309},"0.2.1":{"name":"mocha-cases","version":"0.2.1","description":"A tiny mocha test case runner. Suited for simple input to output validation tests.","main":"index.js","scripts":{"test":"mocha"},"repository":{"type":"git","url":"git+https://github.com/amobiz/mocha-cases.git"},"keywords":["mocha","test","cases","runner","json"],"author":{"name":"Amobiz","email":"amobiz.tw+github@gmail.com","url":"https://github.com/amobiz"},"contributors":[{"name":"Ivan Sosnin","email":"vansosnin@gmail.com","url":"https://github.com/vansosnin"}],"license":"MIT","bugs":{"url":"https://github.com/amobiz/mocha-cases/issues"},"homepage":"https://github.com/amobiz/mocha-cases#readme","peerDependencies":{"mocha":">=2.3.4"},"devDependencies":{"eslint":"^4.15.0","mocha":"^4.1.0"},"dependencies":{"async-done":"^1.2.3","chai":"^4.1.2"},"gitHead":"826be75b0c1e751a571c04f343ed476d32416b02","_id":"mocha-cases@0.2.1","_npmVersion":"5.6.0","_nodeVersion":"6.10.3","_npmUser":{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"},"dist":{"shasum":"fc499fb7c413a86b2234df8f0709dd701398d929","size":4326,"noattachment":false,"key":"/mocha-cases/-/mocha-cases-0.2.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/mocha-cases/download/mocha-cases-0.2.1.tgz"},"maintainers":[{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mocha-cases-0.2.1.tgz_1516721165219_0.5154848385136575"},"directories":{},"publish_time":1516721165590,"_cnpm_publish_time":1516721165590,"_hasShrinkwrap":false},"0.2.0":{"name":"mocha-cases","version":"0.2.0","description":"A tiny mocha test case runner. Suited for simple input to output validation tests.","main":"index.js","scripts":{"test":"mocha"},"repository":{"type":"git","url":"git+https://github.com/amobiz/mocha-cases.git"},"keywords":["mocha","test","cases","runner","json"],"author":{"name":"Amobiz","email":"amobiz.tw+github@gmail.com","url":"https://github.com/amobiz"},"contributors":[{"name":"Ivan Sosnin","email":"vansosnin@gmail.com","url":"https://github.com/vansosnin"}],"license":"MIT","bugs":{"url":"https://github.com/amobiz/mocha-cases/issues"},"homepage":"https://github.com/amobiz/mocha-cases#readme","peerDependencies":{"mocha":">=2.3.4"},"devDependencies":{"eslint":"^4.15.0","mocha":"^4.1.0"},"dependencies":{"async-done":"^1.2.3","chai":"^4.1.2"},"gitHead":"7a3295d84789b08f12cbb3de530776803fe81efa","_id":"mocha-cases@0.2.0","_npmVersion":"5.6.0","_nodeVersion":"6.10.3","_npmUser":{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"},"dist":{"shasum":"db1b9cae0e03845ab3d51f91f3be5a76632b9a8e","size":4170,"noattachment":false,"key":"/mocha-cases/-/mocha-cases-0.2.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/mocha-cases/download/mocha-cases-0.2.0.tgz"},"maintainers":[{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/mocha-cases-0.2.0.tgz_1515877280659_0.05870748125016689"},"directories":{},"publish_time":1515877280789,"_hasShrinkwrap":false,"_cnpm_publish_time":1515877280789},"0.1.10":{"name":"mocha-cases","version":"0.1.10","description":"A tiny mocha test case runner. Suited for simple input to output validation tests.","main":"index.js","scripts":{"test":"mocha"},"repository":{"type":"git","url":"git+https://github.com/amobiz/mocha-cases.git"},"keywords":["mocha","test","cases","runner","json"],"author":{"name":"Amobiz"},"license":"MIT","bugs":{"url":"https://github.com/amobiz/mocha-cases/issues"},"homepage":"https://github.com/amobiz/mocha-cases#readme","peerDependencies":{"mocha":"^2.3.4"},"devDependencies":{"mocha":"^2.3.4"},"dependencies":{"async-done":"^1.2.0","chai":"^3.4.1"},"gitHead":"ac05b338c69ec2fadf4635fc055fafce970aa0ed","_id":"mocha-cases@0.1.10","_shasum":"32bae9e02d68a87c2ef1f328bfd7127aeaf76b69","_from":".","_npmVersion":"3.3.12","_nodeVersion":"5.2.0","_npmUser":{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"},"dist":{"shasum":"32bae9e02d68a87c2ef1f328bfd7127aeaf76b69","size":3795,"noattachment":false,"key":"/mocha-cases/-/mocha-cases-0.1.10.tgz","tarball":"http://registry.cnpm.dingdandao.com/mocha-cases/download/mocha-cases-0.1.10.tgz"},"maintainers":[{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"}],"directories":{},"publish_time":1452190236507,"_cnpm_publish_time":1452190236507,"_hasShrinkwrap":false},"0.1.9":{"name":"mocha-cases","version":"0.1.9","description":"A tiny mocha test case runner. Suited for simple input to output validation tests.","main":"index.js","scripts":{"test":"mocha"},"repository":{"type":"git","url":"git+https://github.com/amobiz/mocha-cases.git"},"keywords":["mocha","test","cases","runner","json"],"author":{"name":"Amobiz"},"license":"MIT","bugs":{"url":"https://github.com/amobiz/mocha-cases/issues"},"homepage":"https://github.com/amobiz/mocha-cases#readme","peerDependencies":{"mocha":"^2.3.4"},"devDependencies":{"mocha":"^2.3.4"},"dependencies":{"async-done":"^1.2.0","chai":"^3.4.1"},"gitHead":"7f31e577966acac55e2f131151e4f1a773914188","_id":"mocha-cases@0.1.9","_shasum":"1d7d03cf16155f0a179ac506d7ed2af8d34f06c9","_from":".","_npmVersion":"3.3.12","_nodeVersion":"5.2.0","_npmUser":{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"},"dist":{"shasum":"1d7d03cf16155f0a179ac506d7ed2af8d34f06c9","size":2942,"noattachment":false,"key":"/mocha-cases/-/mocha-cases-0.1.9.tgz","tarball":"http://registry.cnpm.dingdandao.com/mocha-cases/download/mocha-cases-0.1.9.tgz"},"maintainers":[{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"}],"directories":{},"publish_time":1452174070491,"_cnpm_publish_time":1452174070491,"_hasShrinkwrap":false},"0.1.8":{"name":"mocha-cases","version":"0.1.8","description":"A tiny mocha test case runner. Suited for simple input to output validation tests.","main":"index.js","scripts":{"test":"mocha"},"repository":{"type":"git","url":"git+https://github.com/amobiz/mocha-cases.git"},"keywords":["mocha","test","cases","runner","json"],"author":{"name":"Amobiz"},"license":"MIT","bugs":{"url":"https://github.com/amobiz/mocha-cases/issues"},"homepage":"https://github.com/amobiz/mocha-cases#readme","peerDependencies":{"mocha":"^2.3.4"},"devDependencies":{"mocha":"^2.3.4"},"dependencies":{"async-done":"^1.2.0","chai":"^3.4.1"},"gitHead":"5991eae3b23d3ac1dd1dde9a9c5df81fa4e22740","_id":"mocha-cases@0.1.8","_shasum":"95aad962e19dd056a113de41fd457a3aefcd4525","_from":".","_npmVersion":"3.3.12","_nodeVersion":"5.2.0","_npmUser":{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"},"dist":{"shasum":"95aad962e19dd056a113de41fd457a3aefcd4525","size":3485,"noattachment":false,"key":"/mocha-cases/-/mocha-cases-0.1.8.tgz","tarball":"http://registry.cnpm.dingdandao.com/mocha-cases/download/mocha-cases-0.1.8.tgz"},"maintainers":[{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"}],"directories":{},"publish_time":1452093508230,"_cnpm_publish_time":1452093508230,"_hasShrinkwrap":false},"0.1.7":{"name":"mocha-cases","version":"0.1.7","description":"A tiny mocha test case runner. Suited for simple input to output validation tests.","main":"index.js","scripts":{"test":"mocha"},"repository":{"type":"git","url":"git+https://github.com/amobiz/mocha-cases.git"},"keywords":["mocha","test","cases","runner","json"],"author":{"name":"Amobiz"},"license":"MIT","bugs":{"url":"https://github.com/amobiz/mocha-cases/issues"},"homepage":"https://github.com/amobiz/mocha-cases#readme","peerDependencies":{"mocha":"^2.3.4"},"devDependencies":{"mocha":"^2.3.4"},"dependencies":{"async-done":"^1.2.0","chai":"^3.4.1"},"gitHead":"72d589adb2b479491ac2aad14d4ff7eb0e0e5c49","_id":"mocha-cases@0.1.7","_shasum":"e08268fae0266462fd1474e7af4f2d9ad5acc51f","_from":".","_npmVersion":"3.3.12","_nodeVersion":"5.2.0","_npmUser":{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"},"dist":{"shasum":"e08268fae0266462fd1474e7af4f2d9ad5acc51f","size":2921,"noattachment":false,"key":"/mocha-cases/-/mocha-cases-0.1.7.tgz","tarball":"http://registry.cnpm.dingdandao.com/mocha-cases/download/mocha-cases-0.1.7.tgz"},"maintainers":[{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"}],"directories":{},"publish_time":1452088263369,"_cnpm_publish_time":1452088263369,"_hasShrinkwrap":false},"0.1.6":{"name":"mocha-cases","version":"0.1.6","description":"A tiny mocha test case runner. Suited for simple input to output validation tests.","main":"index.js","scripts":{"test":"mocha"},"repository":{"type":"git","url":"git+https://github.com/amobiz/mocha-cases.git"},"keywords":["mocha","test","cases","runner","json"],"author":{"name":"Amobiz"},"license":"MIT","bugs":{"url":"https://github.com/amobiz/mocha-cases/issues"},"homepage":"https://github.com/amobiz/mocha-cases#readme","peerDependencies":{"mocha":"^2.3.4"},"devDependencies":{"mocha":"^2.3.4"},"dependencies":{"chai":"^3.4.1","chai-as-promised":"^5.2.0"},"gitHead":"e1c8014ffe9efab8e488fd32785abf7a03995ad1","_id":"mocha-cases@0.1.6","_shasum":"8c5854fe99718ae6d087404627051a1be45e17e6","_from":".","_npmVersion":"3.3.12","_nodeVersion":"5.2.0","_npmUser":{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"},"dist":{"shasum":"8c5854fe99718ae6d087404627051a1be45e17e6","size":3082,"noattachment":false,"key":"/mocha-cases/-/mocha-cases-0.1.6.tgz","tarball":"http://registry.cnpm.dingdandao.com/mocha-cases/download/mocha-cases-0.1.6.tgz"},"maintainers":[{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"}],"directories":{},"publish_time":1450898027046,"_cnpm_publish_time":1450898027046,"_hasShrinkwrap":false},"0.1.5":{"name":"mocha-cases","version":"0.1.5","description":"A tiny mocha test case runner. Suited for simple input to output validation tests.","main":"index.js","scripts":{"test":"mocha"},"repository":{"type":"git","url":"git+https://github.com/amobiz/mocha-cases.git"},"keywords":["mocha","test","cases","runner","json"],"author":{"name":"Amobiz"},"license":"MIT","bugs":{"url":"https://github.com/amobiz/mocha-cases/issues"},"homepage":"https://github.com/amobiz/mocha-cases#readme","peerDependencies":{"mocha":"^2.3.4"},"devDependencies":{"mocha":"^2.3.4"},"dependencies":{"chai":"^3.4.1","chai-as-promised":"^5.1.0"},"gitHead":"8cfaf53763e76d355f8faceac1b3f85f481c439a","_id":"mocha-cases@0.1.5","_shasum":"678a7fa193ff59168af22c66e22cb0bf5fcc1ae0","_from":".","_npmVersion":"2.14.2","_nodeVersion":"4.0.0","_npmUser":{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"},"dist":{"shasum":"678a7fa193ff59168af22c66e22cb0bf5fcc1ae0","size":3507,"noattachment":false,"key":"/mocha-cases/-/mocha-cases-0.1.5.tgz","tarball":"http://registry.cnpm.dingdandao.com/mocha-cases/download/mocha-cases-0.1.5.tgz"},"maintainers":[{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"}],"directories":{},"publish_time":1450209895833,"_cnpm_publish_time":1450209895833,"_hasShrinkwrap":false},"0.1.4":{"name":"mocha-cases","version":"0.1.4","description":"A tiny mocha test case runner. Suited for simple input to output validation tests.","main":"index.js","scripts":{"test":"mocha ./tests.js"},"repository":{"type":"git","url":"git+https://github.com/amobiz/mocha-cases.git"},"keywords":["mocha","test","cases","runner","json"],"author":{"name":"Amobiz"},"license":"MIT","bugs":{"url":"https://github.com/amobiz/mocha-cases/issues"},"homepage":"https://github.com/amobiz/mocha-cases#readme","peerDependencies":{"mocha":"^2.3.4"},"dependencies":{"chai":"^3.4.1","chai-as-promised":"^5.1.0"},"gitHead":"3985c3ef7b49c24958c813bbbae7b08d575f7baa","_id":"mocha-cases@0.1.4","_shasum":"9ff9804bc1de1676545b8246b6520aa36d750829","_from":".","_npmVersion":"2.14.2","_nodeVersion":"4.0.0","_npmUser":{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"},"dist":{"shasum":"9ff9804bc1de1676545b8246b6520aa36d750829","size":3538,"noattachment":false,"key":"/mocha-cases/-/mocha-cases-0.1.4.tgz","tarball":"http://registry.cnpm.dingdandao.com/mocha-cases/download/mocha-cases-0.1.4.tgz"},"maintainers":[{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"}],"directories":{},"publish_time":1449491044781,"_cnpm_publish_time":1449491044781,"_hasShrinkwrap":false},"0.1.3":{"name":"mocha-cases","version":"0.1.3","description":"A tiny mocha test case runner. Suited for simple input to output validation tests.","main":"index.js","scripts":{"test":"mocha ./tests.js"},"repository":{"type":"git","url":"git+https://github.com/amobiz/mocha-cases.git"},"keywords":["mocha","test","cases","runner","json"],"author":{"name":"Amobiz"},"license":"MIT","bugs":{"url":"https://github.com/amobiz/mocha-cases/issues"},"homepage":"https://github.com/amobiz/mocha-cases#readme","dependencies":{"chai":"^3.4.1","chai-as-promised":"^5.1.0","mocha":"^2.3.4"},"gitHead":"945c8b4b3e1abebb3223cf1ca6f7ba2f8be2f6d8","_id":"mocha-cases@0.1.3","_shasum":"15d23e7c84d5562444b3591965bf6a2a471cb90e","_from":".","_npmVersion":"2.14.2","_nodeVersion":"4.0.0","_npmUser":{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"},"dist":{"shasum":"15d23e7c84d5562444b3591965bf6a2a471cb90e","size":3557,"noattachment":false,"key":"/mocha-cases/-/mocha-cases-0.1.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/mocha-cases/download/mocha-cases-0.1.3.tgz"},"maintainers":[{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"}],"directories":{},"publish_time":1449129376041,"_cnpm_publish_time":1449129376041,"_hasShrinkwrap":false},"0.1.2":{"name":"mocha-cases","version":"0.1.2","description":"A tiny mocha test case runner. Suited for simple input to output validation tests.","main":"index.js","scripts":{"test":"mocha ./tests.js"},"repository":{"type":"git","url":"git+https://github.com/amobiz/mocha-cases.git"},"keywords":["mocha","test","cases","runner","json"],"author":{"name":"Amobiz"},"license":"MIT","bugs":{"url":"https://github.com/amobiz/mocha-cases/issues"},"homepage":"https://github.com/amobiz/mocha-cases#readme","dependencies":{"chai":"^3.4.1","chai-as-promised":"^5.1.0","mocha":"^2.3.4"},"gitHead":"5f37ab72d7a23b56b35f20727723d7d78968549b","_id":"mocha-cases@0.1.2","_shasum":"139073420c82e69ce7bf9fd35a442b603fc9c5e4","_from":".","_npmVersion":"2.14.2","_nodeVersion":"4.0.0","_npmUser":{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"},"dist":{"shasum":"139073420c82e69ce7bf9fd35a442b603fc9c5e4","size":3564,"noattachment":false,"key":"/mocha-cases/-/mocha-cases-0.1.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/mocha-cases/download/mocha-cases-0.1.2.tgz"},"maintainers":[{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"}],"directories":{},"publish_time":1449128732629,"_cnpm_publish_time":1449128732629,"_hasShrinkwrap":false},"0.1.1":{"name":"mocha-cases","version":"0.1.1","description":"A tiny mocha test case runner. Suited for simple input to output validation tests.","main":"index.js","scripts":{"test":"mocha ./tests.js"},"repository":{"type":"git","url":"git+https://github.com/amobiz/mocha-cases.git"},"keywords":["mocha","test","cases","runner","json"],"author":{"name":"Amobiz"},"license":"MIT","bugs":{"url":"https://github.com/amobiz/mocha-cases/issues"},"homepage":"https://github.com/amobiz/mocha-cases#readme","dependencies":{"chai":"^3.4.1","chai-as-promised":"^5.1.0","mocha":"^2.3.4"},"gitHead":"bc4aa38a53aa9ea31b8f7b875420dacb35dc5c4d","_id":"mocha-cases@0.1.1","_shasum":"2784f75508dd5ea9f2d6668b45d1655cf21b5c0a","_from":".","_npmVersion":"2.14.2","_nodeVersion":"4.0.0","_npmUser":{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"},"dist":{"shasum":"2784f75508dd5ea9f2d6668b45d1655cf21b5c0a","size":3279,"noattachment":false,"key":"/mocha-cases/-/mocha-cases-0.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/mocha-cases/download/mocha-cases-0.1.1.tgz"},"maintainers":[{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"}],"directories":{},"publish_time":1449093743469,"_cnpm_publish_time":1449093743469,"_hasShrinkwrap":false},"0.1.0":{"name":"mocha-cases","version":"0.1.0","description":"A tiny mocha test case runner. Suited for simple input to output validation tests.","main":"index.js","scripts":{"test":"test"},"repository":{"type":"git","url":"git+https://github.com/amobiz/mocha-cases.git"},"keywords":["mocha","test","cases","runner","json"],"author":{"name":"Amobiz"},"license":"MIT","bugs":{"url":"https://github.com/amobiz/mocha-cases/issues"},"homepage":"https://github.com/amobiz/mocha-cases#readme","dependencies":{"chai":"^3.4.1","chai-as-promised":"^5.1.0","mocha":"^2.3.4"},"gitHead":"5f7a8e0bd816b3265cebb3e361174be2c7e2fa37","_id":"mocha-cases@0.1.0","_shasum":"0fba6eb09f89cd4a5baa4addd7e69014e9c99621","_from":".","_npmVersion":"2.14.2","_nodeVersion":"4.0.0","_npmUser":{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"},"dist":{"shasum":"0fba6eb09f89cd4a5baa4addd7e69014e9c99621","size":2529,"noattachment":false,"key":"/mocha-cases/-/mocha-cases-0.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/mocha-cases/download/mocha-cases-0.1.0.tgz"},"maintainers":[{"name":"amobiz","email":"amobiz.tw+npmjs@gmail.com"}],"directories":{},"publish_time":1448226348403,"_cnpm_publish_time":1448226348403,"_hasShrinkwrap":false}},"readme":"# mocha-cases\nA tiny mocha test case runner. Suited for simple input to output validation tests.\n\n[![MIT](http://img.shields.io/badge/license-MIT-brightgreen.svg)](https://github.com/amobiz/mocha-cases/blob/master/LICENSE) [![npm version](https://badge.fury.io/js/mocha-cases.svg)](http://badge.fury.io/js/mocha-cases) [![David Dependency Badge](https://david-dm.org/amobiz/mocha-cases.svg)](https://david-dm.org/amobiz/mocha-cases)\n[![Build Status](https://travis-ci.org/amobiz/mocha-cases.svg?branch=master)](https://travis-ci.org/amobiz/mocha-cases)\n\n[![NPM](https://nodei.co/npm/mocha-cases.png?downloads=true&downloadRank=true&stars=true)](https://nodei.co/npm/mocha-cases.png?downloads=true&downloadRank=true&stars=true) [![NPM](https://nodei.co/npm-dl/mocha-cases.png?months=6&height=3)](https://nodei.co/npm/mocha-cases/)\n\n\n## Install\n``` bash\nnpm install mocha-cases\n```\n\n## Usage\n\n### One case one value\n``` javascript\nvar test = require('mocha-cases');\n\nvar cases = [{\n  name: 'should {value.text} equal to {expected.text}', // name of the test,\n                                                        //   a string, supports nested value interpolation\n                                                        //   or a function, takes test value, expected value and options, and returns a string\n  value: { text: 'input value' },                       // input value\n  expected: { text: 'expected output value' },          // expected output value\n  error: RangeError,                                    // expected error value, instance or class\n  runner: function (value, options) {},                 // runner specific to this case\n  options: {},                                          // options specific to this case\n  only: false,                                          // run this case only?\n  skip: false,                                          // skip this case?\n  errback: false                                        // is the runner using an errback (callback)?\n}, {\n  name: 'case 2...',\n  ...\n}];\n\nvar options = {\n  errback: true,                                        // is all test defaults to errback?\n  prefix: ''                                             // prefix to test names\n};\n\nfunction runner(value, options, done) {                 // errback runner takes a `done` callback\n  setTimeout(function () {\n    done(null, 'expected output value');\n  }, 10);\n}\n\ndescribe('module: mocha-cases', function () {\n  describe('feature: cases', function () {\n    test(cases, runner, options);\n  });\n});\n```\n\nDefault pass through runner will be used if no runner provided at all.\n\n### One case vs. multiple values vs. one expected\n\nYou can use an array of `values` with a single `expected` value:\n\n``` javascript\ndescribe('prime number', function () {\n  test({\n    name: 'given prime number {value}, isPrime() returns true',\n    values: [2, 3, 5, 7, 11, 13],\n    expected: true\n  }, isPrime);\n});\n```\n\n### One case vs. multiple values vs. multiple expected\n\nYou can use an array of `values` and an array of `expected` values, to pair multiple given values and expected values:\n\n``` javascript\ndescribe('prime number', function () {\n  test({\n    name: 'given prime number {value}, isPrime() returns true, false otherwise',\n    values:   [2,    3,    4,     5,    6,     7,    8,     9],\n    expected: [true, true, false, true, false, true, false, false],\n    runner: isPrime\n  });\n});\n```\n\nOr, you can use `cases` to specify multiple cases:\n\n``` javascript\ndescribe('prime number', function () {\n  test({\n    name: 'isPrime({value}) should be {expected}',\n    cases: [{\n      value: 2,\n      expected: true\n    }, {\n      value: 3,\n      expected: true\n    }, {\n      value: 4,\n      expected: false\n    }, {\n      value: 5,\n      expected: true\n    }, {\n      value: 6,\n      expected: false\n    }, {\n      value: 7,\n      expected: true\n    }, {\n      value: 8,\n      expected: false\n    }, {\n      value: 9,\n      expected: false\n    }],\n    runner: isPrime\n  });\n});\n```\n\nIf your values are simple enougth, you may want to simplify them with a pair of value / expected value for each case:\n\n``` javascript\ndescribe('prime number', function () {\n  test({\n    name: 'isPrime({value}) should be {expected}',\n    cases: [\n      [2, true],\n      [3, true],\n      [4, false],\n      [5, true],\n      [6, false],\n      [7, true],\n      [8, false],\n      [9, false]\n    ],\n    runner: isPrime\n  });\n});\n```\n\n## Test\n``` bash\n$ npm test\n```\n\n## Alternatives\n\n * [data-driven](https://www.npmjs.com/package/data-driven)\n * [run-mocha-cases](https://www.npmjs.com/package/run-mocha-cases)\n * [mocha-check](https://www.npmjs.com/package/mocha-check)\n\n## Change Logs\n\n* 2019/02/22 - 0.3.0\n\n  * Feature: Allow escaping the brace characters `{` and `}` with `\\\\`.\n  * Feature: Allow entries of `cases` be an object.\n\n* 2018/01/23 - 0.2.1\n\n  * Feature: Accept function for test name\n  * Feature: Add default pass through runner\n\n* 2018/01/14 - 0.2.0\n\n  * NPM: Bump version, update readme and publish to npm.js.\n\n* 2017/12/07 - 0.1.11\n\n  * Feature: New format for adding test-cases.\n\n* 2016/01/08 - 0.1.10\n\n  * Feature: Allow `error` to be an `Error` instance, a class or a normal value.\n  * Feature: Allow test case negate `errback` option that enabled by overall options.\n\n* 2016/01/07 - 0.1.9\n\n  * Feature: Deprecate the `async` option. For sync/async runner that returning value, i.e. primitive value, promise, stream or observable, you don't have to add any option. For async runner that use errback (callback), you need to add `errback` option.\n\n* 2016/01/06 - 0.1.8\n\n  * Feature: Replace `chai-as-promised` with `async-done`. Now async runner can use callback or return promise, stream or observable.\n\n* 2015/12/24 - 0.1.6\n\n  * NPM: Update npm settings.\n\n* 2015/12/16 - 0.1.5\n\n  * Bug Fix: Fix error when expected values array contains falsy value.\n\n* 2015/12/07 - 0.1.4\n\n  * NPM: Move mocha from \"dependencies\" to \"peerDependencies\".\n\n* 2015/12/03 - 0.1.3\n\n  * Feature: Allow multiple values in one case using \"values\" keyword.\n\n* 2015/12/03 - 0.1.1\n\n  * Feature: Make runner optional, or can be defined either in global options or case options.\n  * Feature: Allow value interpolation in test name.\n\n* 2015/11/23 - 0.1.0\n\n  * First release.\n\n## License\nMIT\n\n## Author\n[Amobiz](https://github.com/amobiz)\n\n## Contributor\n[Ivan Sosnin](https://github.com/vansosnin)\n","_attachments":{},"homepage":"https://github.com/amobiz/mocha-cases#readme","bugs":{"url":"https://github.com/amobiz/mocha-cases/issues"},"license":"MIT"}