{"_id":"platoon","_rev":"41-ed22b711611683b6b07de82756ac00e3","name":"platoon","description":"A javascript asynchronous testing framework","dist-tags":{"latest":"0.0.15"},"versions":{"0.0.1":{"name":"platoon","version":"0.0.1","description":"A javascript asynchronous testing framework","keywords":["unit","test"],"author":{"name":"Chris Dickinson"},"directories":{"lib":"./lib"},"main":"./lib/main","bin":{"platoon":"./bin/platoon"},"license":["New BSD License"],"_id":"platoon@0.0.1","engines":{"node":"*"},"_nodeSupported":true,"_npmVersion":"0.2.7-2","_nodeVersion":"v0.3.1-pre","dist":{"tarball":"https://registry.npmjs.org/platoon/-/platoon-0.0.1.tgz","shasum":"66ac6ebbaa97f0be7065ee3117eed7c1a3f289fa","integrity":"sha512-cEbYFG5TVLTauiF0h0ML5Lux2tYVwdFvanuCNbTNzu8gCgJ6y8sbxTZI3ZA4G5YiNGZ8b2sGXxiVA6Sy09sdLg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCMnMXa22qXkqZZk+Udm8PhAoU7q7/QucoFZbSfXaBywQIgRP7s/HcdJtE9fVlz1w27+4nAwGBk/RtABmI01jWiYxA="}]}},"0.0.2":{"name":"platoon","version":"0.0.2","description":"A javascript asynchronous testing framework","keywords":["unit","test"],"author":{"name":"Chris Dickinson"},"directories":{"lib":"./lib"},"main":"./lib/main","bin":{"platoon":"./bin/platoon"},"license":["New BSD License"],"_id":"platoon@0.0.2","engines":{"node":"*"},"_nodeSupported":true,"_npmVersion":"0.2.7-2","_nodeVersion":"v0.3.1-pre","dist":{"tarball":"https://registry.npmjs.org/platoon/-/platoon-0.0.2.tgz","shasum":"71cc28d69d4bc67bcd3a0713df3840e812623661","integrity":"sha512-CmYRb9xKiMHP20iJbMX0EyePSTeSx1yfy+jjX9kj4X5ZzkEg+Qqyx2Oh7GNA9xXqDgDHjESsG+sFM2JsXMT6Ng==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD/lovLpFZRg7ARDsPfN72WqUsdTELJfJKH7An635Fw0gIgcfJqQQmSghyZLaZJtap0p3otkyN63GW1M1eb0q89SPg="}]}},"0.0.3":{"name":"platoon","version":"0.0.3","description":"A javascript asynchronous testing framework","keywords":["unit","test"],"author":{"name":"Chris Dickinson"},"directories":{"lib":"./lib"},"main":"./lib/main","bin":{"platoon":"./bin/platoon"},"license":["New BSD License"],"_id":"platoon@0.0.3","engines":{"node":"*"},"_nodeSupported":true,"_npmVersion":"0.2.7-2","_nodeVersion":"v0.3.1-pre","dist":{"tarball":"https://registry.npmjs.org/platoon/-/platoon-0.0.3.tgz","shasum":"607b44600a8304d1b324f1f9d57a59e3767ee234","integrity":"sha512-thWQHesEtRRyjt437+3p90XBg7H89c/sOefjjBn1rBb1XkP6eSsBMMoRhOwYENpqnXS7ZLZTYXS+HKiNUl8Uow==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDpJ+O7t10YHekC0RfzWFytfe/DaF+lkSUG/GdkaudcqQIgTXKkck3GLuLdOcvnvBTXsUJExn3j1dGjWkGGzmB3bNQ="}]}},"0.0.4":{"name":"platoon","version":"0.0.4","description":"A javascript asynchronous testing framework","keywords":["unit","test"],"author":{"name":"Chris Dickinson"},"dependencies":{"plate":"0.0.1"},"directories":{"lib":"./lib"},"main":"./lib/main","bin":{"platoon":"./bin/platoon","platoon_browser":"./bin/platoon_browser"},"license":["New BSD License"],"_id":"platoon@0.0.4","engines":{"node":"*"},"_nodeSupported":true,"_npmVersion":"0.2.7-2","_nodeVersion":"v0.3.1-pre","dist":{"tarball":"https://registry.npmjs.org/platoon/-/platoon-0.0.4.tgz","shasum":"de096b98013f071f32a01385ad3cb38a0f611bda","integrity":"sha512-zkYeJid0sMbCAxM+AA+Qb49/C44AmdP6hTzHO4CZhGn3HEZAoJAWE3SvjNxnZGfT8haM3paTxRaUuhLVRqCiEQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC500hPVYI61cSpc0BQPhQvZu7p+UY6iJCG8jNJZLVOhAIgTct0JDIaEyk80M6TNyiZIBYw4HdgtYa/V0NphrR6CHg="}]}},"0.0.5":{"name":"platoon","version":"0.0.5","description":"A javascript asynchronous testing framework","keywords":["unit","test"],"author":{"name":"Chris Dickinson"},"directories":{"lib":"./lib"},"main":"./lib/index","bin":{"platoon":"./bin/platoon","platoon_browser":"./bin/platoon_browser"},"license":["New BSD License"],"_id":"platoon@0.0.5","engines":{"node":"*"},"_nodeSupported":true,"_npmVersion":"0.2.7-2","_nodeVersion":"v0.3.1-pre","dist":{"tarball":"https://registry.npmjs.org/platoon/-/platoon-0.0.5.tgz","shasum":"6cd0d2dbef680de8067d079d618aa3a11abc1180","integrity":"sha512-gom5ZGsKRueuaz7XEV0KTZqOeKTeVXMH46+S3nCyVHfMOs72Ip5icLHNoy7TFJeHAKjeHur+aJSPGcwYY5F2Ww==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDZ9cEc7dPdCgoo7kjxS/m5ALDbafbVRq+8LJajLvdt+gIgfXAcDzw76lwlUR0aK4gLi8lV/B+mrjks1j2uAxq5v98="}]}},"0.0.6":{"name":"platoon","version":"0.0.6","description":"A javascript asynchronous testing framework","keywords":["unit","test"],"author":{"name":"Chris Dickinson"},"directories":{"lib":"./lib"},"main":"./lib/index","bin":{"platoon":"./bin/platoon","platoon_browser":"./bin/platoon_browser"},"license":["New BSD License"],"dependencies":{},"devDependencies":{},"_id":"platoon@0.0.6","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.6","_nodeVersion":"v0.4.7","_defaultsLoaded":true,"dist":{"shasum":"c786925e89d1c1d1612fcf00b54766acaa606e27","tarball":"https://registry.npmjs.org/platoon/-/platoon-0.0.6.tgz","integrity":"sha512-C7WpWyEaGLfxIxS1cw38SoVTenraKNenyeG00bZzCMmy3Xr93JA8cClwq3RoKxoWxWXYW1dpPCkTUfhP1/DU3w==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDGZHgcAhDBZiK1JJeAXx6Xd6L3bCDiXzmESleMdbbHGwIhANgSf3rnfVhZz3KtfaPV8qqxiWDPurN7fTCM8bYdQPVn"}]},"scripts":{}},"0.0.7":{"name":"platoon","version":"0.0.7","description":"A javascript asynchronous testing framework","keywords":["unit","test"],"author":{"name":"Chris Dickinson"},"directories":{"lib":"./lib"},"main":"./lib/index","dependencies":{"tracejs":"0.1.X"},"bin":{"platoon":"./bin/platoon","platoon_browser":"./bin/platoon_browser"},"license":["New BSD License"],"_id":"platoon@0.0.7","devDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.9-1","_nodeVersion":"v0.4.0","_defaultsLoaded":true,"dist":{"shasum":"d6554340abe236e67e543fb02772a13fc0ac82fc","tarball":"https://registry.npmjs.org/platoon/-/platoon-0.0.7.tgz","integrity":"sha512-us/9bN+RTSKO8BHzJQcMD/P6MQA/JAuvHhVJn2MUKcJzn/bEFMwBlxJikQ5sSdvG7CNVDdUIf8ndXAff9yL/AQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIHYTgemdAW9NLzeYwmKD/BGMBMPA9LponBx7e9628nHMAiBkxWqaQ2Mnct3+FjT/t2AAauO7Ms1gje8qWfmG0m9OzQ=="}]},"scripts":{}},"0.0.8":{"name":"platoon","version":"0.0.8","description":"A javascript asynchronous testing framework","keywords":["unit","test"],"author":{"name":"Chris Dickinson"},"directories":{"lib":"./lib"},"main":"./lib/index","dependencies":{"tracejs":"0.1.X","bunker":"0.X.X","nopt":"0.X.X"},"bin":{"platoon":"./bin/platoon","platoon_browser":"./bin/platoon_browser"},"license":["New BSD License"],"devDependencies":{},"_id":"platoon@0.0.8","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.6","_nodeVersion":"v0.4.9","_defaultsLoaded":true,"dist":{"shasum":"09efc3ffa726abbd984110fa6b7aca80dfe9e12f","tarball":"https://registry.npmjs.org/platoon/-/platoon-0.0.8.tgz","integrity":"sha512-kpSsX2AooTuuvXM6KcxF9CnvjsFEf/xvEnLt3QRfYkxbe9Tg+hpVhCuT25MZ9+SATfoCzpSl31oJZ7MrTNajsA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICALnvdwnAvsB2MRt+pSoai/3eCkMqjEfiX61pK+b/vCAiAGWt94DK3x+leQ7GYIBspRG0fP/htFIB9wuqsyhbYing=="}]},"scripts":{}},"0.0.9":{"name":"platoon","version":"0.0.9","description":"A javascript asynchronous testing framework","keywords":["unit","test"],"author":{"name":"Chris Dickinson"},"directories":{"lib":"./lib"},"main":"./lib/index","dependencies":{"tracejs":"0.1.X","runforcover":"0.X.X","nopt":"1.X.X"},"bin":{"platoon":"./bin/platoon","platoon_browser":"./bin/platoon_browser"},"license":["New BSD License"],"devDependencies":{},"_id":"platoon@0.0.9","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.6","_nodeVersion":"v0.4.7","_defaultsLoaded":true,"dist":{"shasum":"bcec1b4a6d55eea0e5001ce98f032e829860478c","tarball":"https://registry.npmjs.org/platoon/-/platoon-0.0.9.tgz","integrity":"sha512-6ugqd6GL/GvkneXoT48kZPo285D+FuO3Szram/tEsZc15DIOFgYC3xJRkteS9Hbwxqo5kdJRO6IdFFpYBv7kQQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFhnD5mRMAtm9bBltD+MNN70UW7c5MrF3JoYlj4h9y/XAiAQq/TWXGV4UPvQVp5DQ2LZla/dfPHAIExmBGm5lOw7Jg=="}]},"scripts":{},"maintainers":[{"name":"chrisdickinson","email":"chris@neversaw.us"}]},"0.0.10":{"name":"platoon","version":"0.0.10","description":"A javascript asynchronous testing framework","keywords":["unit","test"],"author":{"name":"Chris Dickinson"},"directories":{"lib":"./lib"},"main":"./lib/index","dependencies":{"tracejs":"0.1.X","runforcover":"0.X.X","nopt":"1.X.X"},"bin":{"platoon":"./bin/platoon","platoon_browser":"./bin/platoon_browser"},"license":["New BSD License"],"devDependencies":{},"_id":"platoon@0.0.10","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.6","_nodeVersion":"v0.4.7","_defaultsLoaded":true,"dist":{"shasum":"d19c117f66a6e45fe366c3b63a276bdbbeb3772d","tarball":"https://registry.npmjs.org/platoon/-/platoon-0.0.10.tgz","integrity":"sha512-jb5fFEO838GiSxHRZ5U9LVTjLqlZkGbjJEG3FtxGXarmcZmN0NqPlAJTLc4Lfvwc2tVSlkp0SIjyfTLkv7xWbQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCwTfWGA4dep3GqIHDV6gkY/lpXXdiili+MWrwCYXSQdgIhAJR59ee8awdzX4fP6wdgoZdNhJzRsDcwzs8RUpz1nm+v"}]},"scripts":{},"maintainers":[{"name":"chrisdickinson","email":"chris@neversaw.us"}]},"0.0.11":{"name":"platoon","version":"0.0.11","description":"A javascript asynchronous testing framework","keywords":["unit","test"],"author":{"name":"Chris Dickinson"},"directories":{"lib":"./lib"},"main":"./lib/index","dependencies":{"tracejs":"0.1.X","runforcover":"0.X.X","nopt":"1.X.X"},"bin":{"platoon":"./bin/platoon","platoon_browser":"./bin/platoon_browser"},"license":["New BSD License"],"_npmUser":{"name":"chrisdickinson","email":"chris@neversaw.us"},"_id":"platoon@0.0.11","devDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.0-alpha-2","_nodeVersion":"v0.6.3","_defaultsLoaded":true,"dist":{"shasum":"220146126a6014fee689e8fc7db50d762ccfb7ae","tarball":"https://registry.npmjs.org/platoon/-/platoon-0.0.11.tgz","integrity":"sha512-9Ic+OjeDGi/0Vny6ruD60hg7J5PYHgF4IYnbT42KyVhuuboUIo/X2N9LTom1QXV2H3by5TO4taYpQoW9g07snw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGsrxNReLEFmJDjXN9MkTrxcSD+AXB4Wrmv2KMXQl7+IAiEAlgKcfLsSmjB1DNxTrb53c/fNQ2dq+P/wrGa4nTvOxJc="}]},"maintainers":[{"name":"chrisdickinson","email":"chris@neversaw.us"}]},"0.0.12":{"name":"platoon","version":"0.0.12","description":"A javascript asynchronous testing framework","keywords":["unit","test"],"author":{"name":"Chris Dickinson"},"directories":{"lib":"./lib"},"main":"./lib/index","dependencies":{"tracejs":"0.1.X","nopt":"1.X.X"},"bin":{"platoon":"./bin/platoon","platoon_browser":"./bin/platoon_browser"},"license":["New BSD License"],"_npmUser":{"name":"chrisdickinson","email":"chris@neversaw.us"},"_id":"platoon@0.0.12","devDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.0-alpha-2","_nodeVersion":"v0.6.3","_defaultsLoaded":true,"dist":{"shasum":"a285bb8f27ffccbab6facdebf2fba8d857cbb670","tarball":"https://registry.npmjs.org/platoon/-/platoon-0.0.12.tgz","integrity":"sha512-QEgkYusROHFEIPM8Gbwdv2cQIDQaa20YHWO0MTPB7VMRXPf36B4HKSt9nDYfDTG9o7u34SHaFbQVYVwu/Nd1qQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIAUolSYfz1xeUUx69+Dg/G4Wev88wUe9qmDSjeTSPMEeAiEA83+bmjUGZ6YE5/etJ9nz1S2ceXeAzcBzaXZHPEr/dvI="}]},"maintainers":[{"name":"chrisdickinson","email":"chris@neversaw.us"}]},"0.0.13":{"name":"platoon","version":"0.0.13","description":"A javascript asynchronous testing framework","keywords":["unit","test"],"author":{"name":"Chris Dickinson"},"directories":{"lib":"./lib"},"main":"./lib/index","dependencies":{"tracejs":"0.1.X","nopt":"1.X.X"},"bin":{"platoon":"./bin/platoon"},"license":["New BSD License"],"_npmUser":{"name":"chrisdickinson","email":"chris@neversaw.us"},"_id":"platoon@0.0.13","devDependencies":{},"optionalDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.0","_nodeVersion":"v0.6.3","_defaultsLoaded":true,"dist":{"shasum":"01f11ed3504bb2d9fc121f39c08a111bd57e919f","tarball":"https://registry.npmjs.org/platoon/-/platoon-0.0.13.tgz","integrity":"sha512-2zMIL4/tmkbnCertDNiVzkRhpAQEzRaL7t+LULKWx0KRrhcjigQVwleAJat9B7sevmtroE4nwAxdeO/SPYBg0A==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFfv8Btx30hf34Arl2Z9duvUumPyTNfxuPmQn0FKpF/MAiBde0S9oBL4RIPky8wAieBItV9bzrPVtajB6EB8o04fWQ=="}]},"readme":"PLATOON\n===========================\n\nA simple testing framework centered around the thought that Javascript test frameworks should operate on callbacks\nso asynchronous bits aren't quite so much of a hassle to test.\n\nRunning tests\n---------------------------\nAssuming you've installed the package, you should have `platoon` on your `$PATH`, so you can:\n\n    platoon <testfile>\n\nOr just run platoon and let it try to figure out where your tests are (it looks for `tests.js`)\n\nWriting tests\n---------------------------\nThis should seem (mostly) very familiar to you if you've used any other Javascript testing framework (vows.js, qunit, etc).\n\n    var platoon = require('platoon');\n\n    exports.ExampleTest = platoon.unit({\n        setUp:function(callback) {\n            callback();\n        },\n        tearDown:function(callback) {\n            callback();\n        },\n    },\n    function(assert) {\n        \"The name of this particular test item\";\n        assert.equal(0, 0);\n        assert.throws(Error, function() {\n            throw new Error();\n        });\n    },\n    function(assert) {\n        \"The name of another test item\";\n        var Actor = function() {},\n            garyBusey = new Actor();\n        assert.isInstance(garyBusey, Actor);\n        assert.isInstance(garyBusey, [String, Actor, Object]);  // if it's any one of these types, it'll pass\n    });\n\n\nWould be the basic example. **Note the single line strings**: they are the description strings for your test function. Also not that `setUp` and `tearDown` take a callback each, and **must** explicitly execute it when they're done (this lets you do asynchronous setup -- for instance, if you need to grab data from a server before running your test, or if you need to delete something from a database after your test.)\n\nFor asynchronous tests:\n\n    exports.AsyncTest = platoon.unit({},\n        function(assert) {\n            jQuery.getJSON('/some/resource', assert.async(function(data) { \n                assert.equal(data.length, some_number);\n            }));\n    });\n\nAnd now your unit test won't exit until the wrapped `assert.async` function is called.\n\nAssertion Functions\n-------------------\n\n* ok (value)\n* fail (value)\n* equal (lhs, rhs)\n* notEqual (lhs, rhs)\n* strictEqual (lhs, rhs)\n* strictNotEqual (lhs, rhs)\n* throws (type, fn, args_to_fn...)\n* doesNotThrow (fn)\n* isInstance (obj, type | [type1, type2, type3])\n\n\n\n\n","maintainers":[{"name":"chrisdickinson","email":"chris@neversaw.us"}]},"0.0.14":{"name":"platoon","version":"0.0.14","description":"A javascript asynchronous testing framework","keywords":["unit","test"],"author":{"name":"Chris Dickinson"},"directories":{"lib":"./lib"},"main":"./lib/index","dependencies":{"tracejs":"0.1.X","nopt":"1.X.X"},"bin":{"platoon":"./bin/platoon"},"license":["New BSD License"],"_npmUser":{"name":"chrisdickinson","email":"chris@neversaw.us"},"_id":"platoon@0.0.14","devDependencies":{},"optionalDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.0","_nodeVersion":"v0.6.3","_defaultsLoaded":true,"dist":{"shasum":"e04550d5d728b14dec43f46adedddea765a213dc","tarball":"https://registry.npmjs.org/platoon/-/platoon-0.0.14.tgz","integrity":"sha512-CXSYADUnXMP0InGnxowz4t0beamFNoPM9s+2ABE1puoqEq2qGVcCiIeLj3rUjYlQQuIRDl0IAwn4TqcDtfqbjg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIGwr29YXodV026KxViGQHONA90Ra5dY81A8XrBrg3SyDAiBBlv9/w3XAxSeYrBMZv9RfFobs8MNV6LoH/Wdd/dX/RQ=="}]},"readme":"PLATOON\n===========================\n\nA simple testing framework centered around the thought that Javascript test frameworks should operate on callbacks\nso asynchronous bits aren't quite so much of a hassle to test.\n\nRunning tests\n---------------------------\nAssuming you've installed the package, you should have `platoon` on your `$PATH`, so you can:\n\n    platoon <testfile>\n\nOr just run platoon and let it try to figure out where your tests are (it looks for `tests.js`)\n\nWriting tests\n---------------------------\nThis should seem (mostly) very familiar to you if you've used any other Javascript testing framework (vows.js, qunit, etc).\n\n    var platoon = require('platoon');\n\n    exports.ExampleTest = platoon.unit({\n        setUp:function(callback) {\n            callback();\n        },\n        tearDown:function(callback) {\n            callback();\n        },\n    },\n    function(assert) {\n        \"The name of this particular test item\";\n        assert.equal(0, 0);\n        assert.throws(Error, function() {\n            throw new Error();\n        });\n    },\n    function(assert) {\n        \"The name of another test item\";\n        var Actor = function() {},\n            garyBusey = new Actor();\n        assert.isInstance(garyBusey, Actor);\n        assert.isInstance(garyBusey, [String, Actor, Object]);  // if it's any one of these types, it'll pass\n    });\n\n\nWould be the basic example. **Note the single line strings**: they are the description strings for your test function. Also not that `setUp` and `tearDown` take a callback each, and **must** explicitly execute it when they're done (this lets you do asynchronous setup -- for instance, if you need to grab data from a server before running your test, or if you need to delete something from a database after your test.)\n\nFor asynchronous tests:\n\n    exports.AsyncTest = platoon.unit({},\n        function(assert) {\n            jQuery.getJSON('/some/resource', assert.async(function(data) { \n                assert.equal(data.length, some_number);\n            }));\n    });\n\nAnd now your unit test won't exit until the wrapped `assert.async` function is called.\n\nAssertion Functions\n-------------------\n\n* ok (value)\n* fail (value)\n* equal (lhs, rhs)\n* notEqual (lhs, rhs)\n* strictEqual (lhs, rhs)\n* strictNotEqual (lhs, rhs)\n* throws (type, fn, args_to_fn...)\n* doesNotThrow (fn)\n* isInstance (obj, type | [type1, type2, type3])\n\n\n\n\n","maintainers":[{"name":"chrisdickinson","email":"chris@neversaw.us"}]},"0.0.15":{"name":"platoon","version":"0.0.15","description":"A javascript asynchronous testing framework","keywords":["unit","test"],"author":{"name":"Chris Dickinson"},"directories":{"lib":"./lib"},"main":"./lib/index","dependencies":{"tracejs":"0.1.X","nopt":"1.X.X"},"bin":{"platoon":"./bin/platoon"},"license":["New BSD License"],"_npmUser":{"name":"chrisdickinson","email":"chris@neversaw.us"},"_id":"platoon@0.0.15","devDependencies":{},"optionalDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.0","_nodeVersion":"v0.6.3","_defaultsLoaded":true,"dist":{"shasum":"d1c596394089a12f6e72982c2e5e7bd430c71605","tarball":"https://registry.npmjs.org/platoon/-/platoon-0.0.15.tgz","integrity":"sha512-3/ya78zUgr0TvGSmmi0VYGVOjVIqOtRE5aF/2UwAtfPJa0z7FCdpux4MCLBScfVfV9tUM5uuybWKJvoFRdMVuw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDKZYlcL/ZNteQt1ntXCi/dvcK/mnNlu0FWdjUEBm6MFwIhAI5en5/bJyJmsPS3MhFpMtUkc3QWojIlckOkWUEkb5FU"}]},"readme":"PLATOON\n===========================\n\nA simple testing framework centered around the thought that Javascript test frameworks should operate on callbacks\nso asynchronous bits aren't quite so much of a hassle to test.\n\nRunning tests\n---------------------------\nAssuming you've installed the package, you should have `platoon` on your `$PATH`, so you can:\n\n    platoon <testfile>\n\nOr just run platoon and let it try to figure out where your tests are (it looks for `tests.js`)\n\nWriting tests\n---------------------------\nThis should seem (mostly) very familiar to you if you've used any other Javascript testing framework (vows.js, qunit, etc).\n\n    var platoon = require('platoon');\n\n    exports.ExampleTest = platoon.unit({\n        setUp:function(callback) {\n            callback();\n        },\n        tearDown:function(callback) {\n            callback();\n        },\n    },\n    function(assert) {\n        \"The name of this particular test item\";\n        assert.equal(0, 0);\n        assert.throws(Error, function() {\n            throw new Error();\n        });\n    },\n    function(assert) {\n        \"The name of another test item\";\n        var Actor = function() {},\n            garyBusey = new Actor();\n        assert.isInstance(garyBusey, Actor);\n        assert.isInstance(garyBusey, [String, Actor, Object]);  // if it's any one of these types, it'll pass\n    });\n\n\nWould be the basic example. **Note the single line strings**: they are the description strings for your test function. Also not that `setUp` and `tearDown` take a callback each, and **must** explicitly execute it when they're done (this lets you do asynchronous setup -- for instance, if you need to grab data from a server before running your test, or if you need to delete something from a database after your test.)\n\nFor asynchronous tests:\n\n    exports.AsyncTest = platoon.unit({},\n        function(assert) {\n            jQuery.getJSON('/some/resource', assert.async(function(data) { \n                assert.equal(data.length, some_number);\n            }));\n    });\n\nAnd now your unit test won't exit until the wrapped `assert.async` function is called.\n\nAssertion Functions\n-------------------\n\n* ok (value)\n* fail (value)\n* equal (lhs, rhs)\n* notEqual (lhs, rhs)\n* strictEqual (lhs, rhs)\n* strictNotEqual (lhs, rhs)\n* throws (type, fn, args_to_fn...)\n* doesNotThrow (fn)\n* isInstance (obj, type | [type1, type2, type3])\n\n\n\n\n","maintainers":[{"name":"chrisdickinson","email":"chris@neversaw.us"}]}},"maintainers":[{"name":"chrisdickinson","email":"chris@neversaw.us"}],"author":{"name":"Chris Dickinson"},"time":{"modified":"2022-06-24T02:55:56.599Z","created":"2011-06-23T00:31:40.180Z","0.0.1":"2011-06-23T00:31:40.180Z","0.0.2":"2011-06-23T00:31:40.180Z","0.0.3":"2011-06-23T00:31:40.180Z","0.0.4":"2011-06-23T00:31:40.180Z","0.0.5":"2011-06-23T00:31:40.180Z","0.0.6":"2011-06-23T00:31:40.180Z","0.0.7":"2011-06-23T00:35:44.400Z","0.0.8":"2011-07-21T19:14:25.515Z","0.0.9":"2011-08-11T04:10:15.304Z","0.0.10":"2011-08-11T04:11:58.976Z","0.0.11":"2012-01-13T22:50:55.820Z","0.0.12":"2012-01-14T04:07:22.094Z","0.0.13":"2012-01-19T07:13:47.565Z","0.0.14":"2012-01-19T07:30:01.915Z","0.0.15":"2012-01-19T20:59:26.925Z"}}