{"name":"@wdio/mocha-framework","version":"6.0.0-alpha.1","keywords":["webdriver","wdio","wdio-reporter"],"author":{"name":"Christian Bromann","email":"christian@saucelabs.com"},"license":"MIT","_id":"@wdio/mocha-framework@6.0.0-alpha.1","maintainers":[{"name":"abjerstedt","email":"abjerstedt@gmail.com"},{"name":"christian-bromann","email":"christian@saucelabs.com"},{"name":"erwinheitzman","email":"erwin.heitzman.npm@gmail.com"},{"name":"klamping","email":"me@klamp.in"},{"name":"mgrybyk","email":"mykola.grybyk@gmail.com"},{"name":"wdio-user","email":"christian+webdriverio@saucelabs.com"},{"name":"willbrock","email":"wpbrock@gmail.com"}],"homepage":"https://github.com/webdriverio/webdriverio/tree/master/packages/wdio-mocha-framework","bugs":{"url":"https://github.com/webdriverio/webdriverio/issues"},"dist":{"shasum":"42f3bd436356749ca2df90b5d8b012ab2331798c","tarball":"http://registry-npm.ywwl.com/@wdio/mocha-framework/download/@wdio/mocha-framework-6.0.0-alpha.1.tgz","fileCount":6,"integrity":"sha512-2TddHqDWhCBvSHKyHQPmpxcfpd2Ozl/1EWhzDj9A9OIWyCpAxNWLM0324JVbZWtDkG75aHwXvaqkJEKh81tBkQ==","signatures":[{"sig":"MEUCIQDecjcG9EpX9kYsMh95qaabY0aLF3oyn/U3Z/g6KqwUiAIga9OnsTOMWkq+aIV6Dn7ci5Wi1UygGWzwNKr2E48ios8=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":15662,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeHxVGCRA9TVsSAnZWagAA3MIP/j/+58339IZdA/SwJwzZ\nG2xo2WzRBb1McxDe7WcOkGi55cJuMtmlukWA4YwuIcrB8wRaO0R9Mbqsewbx\ngZMKmuMLt6FtIHHR2C++ZMPw9hv5GA93arKd4EsyU31NrVUXrZhwI/bGD96S\nLa1FrJMR0Bv3NuruLsPfTIibpkbZ0EjBwv6ptEg0AOqBq3TcwiMVnt6PrCP4\nTyqAddTO/neUPBPUv5BGnN9kbJUANBJeufZAznzCnNjxoSWI5bsKDev4y/28\nQqY87gwAPVYxvQicKHKc68c6VKQTPwonSuEknatKf3evgZTHj4lKySMui3DC\nEX2c4LZIxuuXqWmcjk2BQcx88bX8xro4JpPYW+Jy2i7QbVapR2L/E3TJu40a\n6laUwlL7M62/6/oXyl4qx0bVjaTcVxhiIGwxCt1Mm17HCWOi4IpOKLULd+2k\nmBE7rM3jz7btQOnGHymhUA+G1bsCTK6cycUEyDWECv8RqIHp/ATBHe9wdAh6\n+fQp5LB/leJnfEzI9ERP/rOYX2f3MCqq8662uTZGQ56hgtJW/faFcfSRqT2Q\nifjBgQobtWfn8Yq4I1lZLZM2GsLHfrL4/zdJ/X8yMMQvXp3jzKZuaNfXwpMb\nXEt0cDiuyn1SFiyh2tiQUfF4/dbCJnkbySVFAnVbC9aOZ98ZaFYQyRqFxhY3\nx9L0\r\n=F7M6\r\n-----END PGP SIGNATURE-----\r\n","size":5479,"noattachment":false,"key":"/@wdio/mocha-framework/-/@wdio/mocha-framework-6.0.0-alpha.1.tgz"},"main":"./build/index","types":"mocha-framework.d.ts","engines":{"node":">=10.0.0"},"gitHead":"1b11d192fa30cd92724a21e3febbf40b9e5b3ba2","scripts":{"test":"run-s test:*","build":"run-s clean compile","clean":"rimraf ./build","compile":"babel src/ -d build/ --config-file ../../babel.config.js","test:unit":"jest","test:eslint":"eslint src test"},"_npmUser":{"name":"christian-bromann","email":"christian@saucelabs.com"},"repository":{"url":"git://github.com/webdriverio/webdriverio.git","type":"git"},"_npmVersion":"lerna/3.19.0/node@v10.15.0+x64 (darwin)","description":"A WebdriverIO plugin. Adapter for Mocha testing framework.","directories":{},"_nodeVersion":"10.15.0","dependencies":{"mocha":"^6.1.0","@wdio/utils":"6.0.0-alpha.1","@wdio/logger":"6.0.0-alpha.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"readmeFilename":"README.md","devDependencies":{"@types/mocha":"^5.2.5"},"peerDependencies":{"webdriverio":"^5.0.0"},"_npmOperationalInternal":{"tmp":"tmp/mocha-framework_6.0.0-alpha.1_1579095365957_0.41847445901850766","host":"s3://npm-registry-packages"},"readme":"WDIO Mocha Framework Adapter\n============================\n\n> A WebdriverIO plugin. Adapter for Mocha testing framework.\n\n## Installation\n\nThe easiest way is to keep `@wdio/mocha-framework` as a devDependency in your `package.json`, via:\n\n```sh\nnpm install @wdio/mocha-framework --save-dev\n```\n\nInstructions on how to install `WebdriverIO` can be found [here.](https://webdriver.io/docs/gettingstarted)\n\n## Configuration\n\nFollowing code shows the default wdio test runner configuration...\n\n```js\n// wdio.conf.js\nmodule.exports = {\n  // ...\n  framework: 'mocha',\n\n  mochaOpts: {\n    ui: 'bdd'\n  }\n  // ...\n};\n```\n\nNote that interfaces supported are `bdd`, `tdd` and `qunit`. If you want to provide a custom interface, it should expose methods compatible with them and be named ending with `-bdd`, `-tdd` or `-qunit` accordingly.\n\n## `mochaOpts` Options\n\nOptions will be passed to the Mocha instance. See the list of supported Mocha options [here](https://github.com/mochajs/mocha/wiki/Using-mocha-programmatically#set-options).\n\n`failHookAffectedTests` defaults to `true`. When a `before` or `beforeEach` hook fails, the tests that hook skipped are reported as failed. Set `failHookAffectedTests: false` to report only the hook.\n\n----\n\n## `mochaOpts.require (string|string[])`\n\nThe `require` option is useful when you want to add or extend some basic functionality. <br />\nFor example, let's try to create an anonymous `describe`:\n\n**wdio.conf.js**\n\n```js\n{\n  suites: {\n    login: ['tests/login/*.js']\n  },\n\n  mochaOpts: {\n    require: './hooks/mocha.js'\n  }\n}\n```\n\n**./hooks/mocha.js**\n\n```js\nimport path from 'path';\n\nlet { context, file, mocha, options } = module.parent.context;\nlet { describe } = context;\n\ncontext.describe = function (name, callback) {\n\tif (callback) {\n\t\treturn describe(...arguments);\n\t} else {\n\t\tcallback = name;\n\t\tname = path.basename(file, '.js');\n\n\t\treturn describe(name, callback);\n\t}\n}\n```\n\n**./tests/TEST-XXX.js**\n\n```js\ndescribe(() => {\n\tit('Login form', function () => {\n\t\tthis.skip();\n\t});\n});\n```\n\n**Output**\n\n```\nTEST-XXX\n   ✓ Login form\n```\n\nFor more information on WebdriverIO see the [homepage](https://webdriver.io).\n","publish_time":1579095366068,"_cnpm_publish_time":1579095366068,"dist-tags":{"beta":"7.0.0-beta.4","latest":"10.2.0","latest-5":"5.23.0","next":"10.2.0-alpha.100.sha-b38abd894","v7":"7.40.0","v8":"8.46.0","v9":"9.33.1"}}