{"_id":"@albanv/nock-vcr-recorder-mocha","_rev":"4-6ccb2ffd4da57ef6e98866d600c6f13c","name":"@albanv/nock-vcr-recorder-mocha","description":"Wrapper around nock-vcr-recorder to simplify creating vcr cassettes in mocha.","dist-tags":{"latest":"0.3.4"},"versions":{"0.3.3":{"name":"@albanv/nock-vcr-recorder-mocha","version":"0.3.3","description":"Wrapper around nock-vcr-recorder to simplify creating vcr cassettes in mocha.","main":"index.js","scripts":{"test":"rm -rf cassettes && node_modules/mocha/bin/mocha -r test/_helper.js test/*-test.js "},"repository":{"type":"git","url":"git+https://github.com/poetic/nock-vcr-recorder-mocha.git"},"keywords":["vcr","mocha","nock","testing","fixtures","mocking"],"author":{"name":"Jake Craige","email":"jake@poeticsystems.com"},"license":"MIT","bugs":{"url":"https://github.com/poetic/nock-vcr-recorder-mocha/issues"},"homepage":"https://github.com/poetic/nock-vcr-recorder-mocha","dependencies":{"bluebird":"^3.4.1","nock-vcr-recorder":"^0.1.3"},"devDependencies":{"express":"^4.14.0","mocha":"^2.0.1","request":"^2.73.0","request-promise":"^4.0.1"},"gitHead":"7595edca1f387caf3495fab501e8a93b1fb698f6","_id":"@albanv/nock-vcr-recorder-mocha@0.3.3","_shasum":"02ce86fae1a069a4881f6ee2497a2d3bc1b8285b","_from":".","_npmVersion":"3.9.5","_nodeVersion":"6.2.2","_npmUser":{"name":"albanv","email":"me@alban.io"},"dist":{"shasum":"02ce86fae1a069a4881f6ee2497a2d3bc1b8285b","tarball":"https://registry.npmjs.org/@albanv/nock-vcr-recorder-mocha/-/nock-vcr-recorder-mocha-0.3.3.tgz","integrity":"sha512-8j+ncLAMR1gEi0VnKcwEa0IbffqglXLWvO2vk6BjQNLyNPDVOhsrVzp+Xp91etYx4Fq7KOvQavZKSS0Soc6bKw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD9TAnAcFmkGvkyQOYbOmnMSqe8FcdbsYcO7+oKhlo14wIga7Bj7I4QUY+jdFUUEin6BmNyaB1Js/uhNwtrzyFA8u0="}]},"maintainers":[{"name":"albanv","email":"me@alban.io"}],"_npmOperationalInternal":{"host":"packages-16-east.internal.npmjs.com","tmp":"tmp/nock-vcr-recorder-mocha-0.3.3.tgz_1468855461739_0.4053592667914927"}},"0.3.4":{"name":"@albanv/nock-vcr-recorder-mocha","version":"0.3.4","description":"Wrapper around nock-vcr-recorder to simplify creating vcr cassettes in mocha.","main":"index.js","scripts":{"test":"rm -rf cassettes && node_modules/mocha/bin/mocha -r test/_helper.js test/*-test.js","coverage":"rm -rf cassettes && istanbul cover _mocha -- -r test/_helper.js test/*-test.js","postpublish":"greenkeeper-postpublish"},"repository":{"type":"git","url":"git+https://github.com/vizeat/nock-vcr-recorder-mocha.git"},"keywords":["vcr","mocha","nock","testing","fixtures","mocking"],"author":{"name":"Jake Craige","email":"jake@poeticsystems.com"},"license":"MIT","bugs":{"url":"https://github.com/vizeat/nock-vcr-recorder-mocha/issues"},"homepage":"https://github.com/vizeat/nock-vcr-recorder-mocha","dependencies":{"bluebird":"^3.4.1","@albanv/nock-vcr-recorder":"^0.1.4"},"devDependencies":{"express":"^4.14.0","greenkeeper-postpublish":"^1.0.0","istanbul":"^0.4.4","mocha":"^2.0.1","request":"^2.73.0","request-promise":"^4.0.1"},"gitHead":"0139b398acf172a3256782e395d57c881038d38a","_id":"@albanv/nock-vcr-recorder-mocha@0.3.4","_shasum":"7c06efdcf55cbfafa38866c7a24138a95320d602","_from":".","_npmVersion":"3.10.6","_nodeVersion":"6.2.2","_npmUser":{"name":"albanv","email":"me@alban.io"},"dist":{"shasum":"7c06efdcf55cbfafa38866c7a24138a95320d602","tarball":"https://registry.npmjs.org/@albanv/nock-vcr-recorder-mocha/-/nock-vcr-recorder-mocha-0.3.4.tgz","integrity":"sha512-YgOt/gosc1CBhnBG0AjzIfuosMEMyhAWPRIV1I4gBExGZIh6mnzKYQXxj2WUoqadMaVqPi2lQLYPhgmcKakudA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQC0Z0Pgq86WfhiP/wtAkeWQf+Fuw3GVbFOusc/yR51vbwIhAJFEoD+4i4NYvCyu0wK2qDr2C10an6WjETzoDl7jUsTX"}]},"maintainers":[{"name":"albanv","email":"me@alban.io"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/nock-vcr-recorder-mocha-0.3.4.tgz_1469457193537_0.9568531131371856"}}},"readme":"# Nock VCR Recorder Mocha\n[![Build Status](https://travis-ci.org/vizeat/nock-vcr-recorder-mocha.svg?branch=master)](https://travis-ci.org/vizeat/nock-vcr-recorder-mocha) [![codecov](https://codecov.io/gh/vizeat/nock-vcr-recorder-mocha/branch/master/graph/badge.svg)](https://codecov.io/gh/vizeat/nock-vcr-recorder-mocha) [![npm version](https://badge.fury.io/js/%40albanv%2Fnock-vcr-recorder-mocha.svg)](https://badge.fury.io/js/%40albanv%2Fnock-vcr-recorder-mocha) [![Dependency Status](https://david-dm.org/vizeat/nock-vcr-recorder-mocha.svg)](https://david-dm.org/vizeat/nock-vcr-recorder-mocha)\n\n\n## About\n\nA wrapper around\n[nock-vcr-recorder](https://github.com/vizeat/nock-vcr-recorder) to simplify\ncreating vcr cassettes in mocha.\n\n## Install\n\n```bash\nnpm install --save-dev @albanv/nock-vcr-recorder-mocha\n```\n\n## Usage\n\nWhen you need to record cassettes you can either:\n\n- Use `vcr.describe` instead of `describe`\n- Use `vcr.it` instead of `it`\n\n`vcr.describe` will record a cassette before each test in that block. So\nyou can have multiple `it`s and it will record any requests within them.\n\n`vcr.it` will record a cassette for one specific test.\n\nThey both support `.skip` and `.only` as mocha does.\n\n```js\nvar request = require('request');\nvar assert  = require('assert');\nvar vcr     = require('nock-vcr-recorder-mocha');\n\ndescribe('normal test', function() {\n  vcr.it.only('works', function(done) {\n    request('http://localhost:4000/users', function(err, res, body) {\n      assert(!err, 'was success');\n      done();\n    });\n  });\n\n  it('some other test', function() {\n    // You can use mocha how you normally would to group tests\n  });\n});\n\nvcr.describe.skip('skipped test', function() {\n  // Anything in here will be skipped\n  // If the skip is removed, this request would be recorded for playback in\n  // later tests\n  it('makes request', function(done) {\n    request('http://localhost:4000/users', function(err, res, body) {\n      assert(!err, 'was success');\n      done();\n    });\n  });\n});\n```\n\n## Configuration\n\nList of [available configuration\noptions](https://github.com/poetic/nock-vcr-recorder#configuration)\n\n#### Test specific configuration\n\n```js\nvcr.it('works', {\n  mode: 'all'\n}, function(done) {\n  request('http://localhost:4000/users', function(err, res, body) {\n    assert(!err, 'was success');\n    done();\n  });\n});\n\nvcr.describe('works', { mode: 'all' }, function() {\n  it('makes request', function(done) {\n    request('http://localhost:4000/users', function(err, res, body) {\n      assert(!err, 'was success');\n      done();\n    });\n  });\n});\n```\n\n#### Global Configuration\n\nA `vcr.config` method is exposed to set default configuration on a global level.\nThis should be done before any of your tests have run. In mocha you can put this\nin a helper file.\n\n```js\nvar vcr = require('nock-vcr-recorder-mocha');\n\nncr.config({\n  excludeScope: ['github.com']\n});\n```\n\n## Authors ##\n\n* [Jake Craige](http://twitter.com/jakecraige)\n\n## Versioning\n\nThis library follows [Semantic Versioning](http://semver.org)\n\n## Want to help?\n\nPlease do! We are always looking to improve this library. If you have any ideas\nplease open an issue or a pull requests and we'll work on getting them in.\n\n## Legal\n\n[Poetic Systems](http://poeticsystems.com), Inc &copy; 2014\n\n[@poeticsystems](http://twitter.com/poeticsystems)\n\n[Licensed under the MIT license](http://www.opensource.org/licenses/mit-license.php)\n","maintainers":[{"name":"albanv","email":"me@alban.io"}],"time":{"modified":"2022-06-12T14:27:41.023Z","created":"2016-07-18T15:24:22.977Z","0.3.3":"2016-07-18T15:24:22.977Z","0.3.4":"2016-07-25T14:33:15.653Z"},"homepage":"https://github.com/vizeat/nock-vcr-recorder-mocha","keywords":["vcr","mocha","nock","testing","fixtures","mocking"],"repository":{"type":"git","url":"git+https://github.com/vizeat/nock-vcr-recorder-mocha.git"},"author":{"name":"Jake Craige","email":"jake@poeticsystems.com"},"bugs":{"url":"https://github.com/vizeat/nock-vcr-recorder-mocha/issues"},"license":"MIT","readmeFilename":"README.md"}