UNPKG

ti-appium

Version:

An Appium wrapper to test Titanium applications

567 lines (148 loc) 8.11 kB
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <title>JSDoc: Class: Mocha_Helper</title> <script src="scripts/prettify/prettify.js"> </script> <script src="scripts/prettify/lang-css.js"> </script> <!--[if lt IE 9]> <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script> <![endif]--> <link type="text/css" rel="stylesheet" href="styles/prettify-tomorrow.css"> <link type="text/css" rel="stylesheet" href="styles/jsdoc-default.css"> </head> <body> <div id="main"> <h1 class="page-title">Class: Mocha_Helper</h1> <section> <header> <h2><span class="attribs"><span class="type-signature"></span></span>Mocha_Helper<span class="signature">()</span><span class="type-signature"></span></h2> </header> <article> <div class="container-overview"> <h4 class="name" id="Mocha_Helper"><span class="type-signature"></span>new Mocha_Helper<span class="signature">()</span><span class="type-signature"></span></h4> <div class="description"> Used for pulling in test files, and launching a Mocha test suite. </div> <dl class="details"> <dt class="tag-source">Source:</dt> <dd class="tag-source"><ul class="dummy"><li> <a href="src_mocha.js.html">src/mocha.js</a>, <a href="src_mocha.js.html#line9">line 9</a> </li></ul></dd> </dl> </div> <h3 class="subsection-title">Methods</h3> <h4 class="name" id=".collectTests"><span class="type-signature">(static) </span>collectTests<span class="signature">(dir)</span><span class="type-signature"></span></h4> <div class="description"> Goes through the passed directory, and extracts any tests that match the regular expression. </div> <h5>Parameters:</h5> <table class="params"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>dir</code></td> <td class="type"> <span class="param-type">String</span> </td> <td class="description last">The directory to search</td> </tr> </tbody> </table> <dl class="details"> <dt class="tag-source">Source:</dt> <dd class="tag-source"><ul class="dummy"><li> <a href="src_mocha.js.html">src/mocha.js</a>, <a href="src_mocha.js.html#line21">line 21</a> </li></ul></dd> </dl> <h4 class="name" id=".run"><span class="type-signature">(static) </span>run<span class="signature">(testFiles, modRoot, opts)</span><span class="type-signature"></span></h4> <div class="description"> Runs through the Mocha tests outlined in device_config.js </div> <h5>Parameters:</h5> <table class="params"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>testFiles</code></td> <td class="type"> <span class="param-type">Array</span> </td> <td class="description last">An array of test files for Mocha to run</td> </tr> <tr> <td class="name"><code>modRoot</code></td> <td class="type"> <span class="param-type">String</span> </td> <td class="description last">The path to the root of the project being tested</td> </tr> <tr> <td class="name"><code>opts</code></td> <td class="type"> <span class="param-type">Object</span> </td> <td class="description last">Optional Arguments <h6>Properties</h6> <table class="params"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>timeout</code></td> <td class="type"> <span class="param-type">Int</span> </td> <td class="description last">Timeout threshold for Mocha tests</td> </tr> <tr> <td class="name"><code>slow</code></td> <td class="type"> <span class="param-type">Int</span> </td> <td class="description last">Slow threshold for Mocha tests</td> </tr> </tbody> </table> </td> </tr> </tbody> </table> <dl class="details"> <dt class="tag-source">Source:</dt> <dd class="tag-source"><ul class="dummy"><li> <a href="src_mocha.js.html">src/mocha.js</a>, <a href="src_mocha.js.html#line57">line 57</a> </li></ul></dd> </dl> </article> </section> </div> <nav> <h2><a href="index.html">Home</a></h2><h3>Namespaces</h3><ul><li><a href="WebDriverCommands.html">WebDriverCommands</a></li></ul><h3>Classes</h3><ul><li><a href="Appc_Helper.html">Appc_Helper</a></li><li><a href="Appium_Helper.html">Appium_Helper</a></li><li><a href="Device_Helper.html">Device_Helper</a></li><li><a href="Mocha_Helper.html">Mocha_Helper</a></li><li><a href="Output_Helper.html">Output_Helper</a></li><li><a href="Webdriver_Helper.html">Webdriver_Helper</a></li></ul><h3>Global</h3><ul><li><a href="global.html#appcRun">appcRun</a></li><li><a href="global.html#appcSetup">appcSetup</a></li><li><a href="global.html#banner">banner</a></li><li><a href="global.html#buildApp">buildApp</a></li><li><a href="global.html#createAppPath">createAppPath</a></li><li><a href="global.html#debug">debug</a></li><li><a href="global.html#error">error</a></li><li><a href="global.html#finish">finish</a></li><li><a href="global.html#getCert">getCert</a></li><li><a href="global.html#getProfile">getProfile</a></li><li><a href="global.html#getSimState">getSimState</a></li><li><a href="global.html#info">info</a></li><li><a href="global.html#killEmulator">killEmulator</a></li><li><a href="global.html#killSimulator">killSimulator</a></li><li><a href="global.html#parseSDK">parseSDK</a></li><li><a href="global.html#skip">skip</a></li><li><a href="global.html#startAppium">startAppium</a></li><li><a href="global.html#startClient">startClient</a></li><li><a href="global.html#step">step</a></li><li><a href="global.html#stopAppium">stopAppium</a></li><li><a href="global.html#stopClient">stopClient</a></li><li><a href="global.html#test">test</a></li><li><a href="global.html#warn">warn</a></li></ul> </nav> <br class="clear"> <footer> Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 3.6.3</a> on Fri Aug 28 2020 10:09:07 GMT+0100 (British Summer Time) </footer> <script> prettyPrint(); </script> <script src="scripts/linenumber.js"> </script> </body> </html>