OverviewUsage.html 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333
  1. <!DOCTYPE html>
  2. <!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
  3. <!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
  4. <head>
  5. <meta charset="utf-8">
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7. <title>What is baangt &mdash; baangt 2020.1.1.b11 documentation</title>
  8. <script type="text/javascript" src="_static/js/modernizr.min.js"></script>
  9. <script type="text/javascript" id="documentation_options" data-url_root="./" src="_static/documentation_options.js"></script>
  10. <script type="text/javascript" src="_static/jquery.js"></script>
  11. <script type="text/javascript" src="_static/underscore.js"></script>
  12. <script type="text/javascript" src="_static/doctools.js"></script>
  13. <script type="text/javascript" src="_static/language_data.js"></script>
  14. <script type="text/javascript" src="_static/js/theme.js"></script>
  15. <link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
  16. <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
  17. <link rel="index" title="Index" href="genindex.html" />
  18. <link rel="search" title="Search" href="search.html" />
  19. <link rel="next" title="Jump-start into worry free production deployments" href="simpleExample.html" />
  20. <link rel="prev" title="Installation" href="Installation.html" />
  21. </head>
  22. <body class="wy-body-for-nav">
  23. <div class="wy-grid-for-nav">
  24. <nav data-toggle="wy-nav-shift" class="wy-nav-side">
  25. <div class="wy-side-scroll">
  26. <div class="wy-side-nav-search" >
  27. <a href="index.html" class="icon icon-home"> baangt
  28. </a>
  29. <div role="search">
  30. <form id="rtd-search-form" class="wy-form" action="search.html" method="get">
  31. <input type="text" name="q" placeholder="Search docs" />
  32. <input type="hidden" name="check_keywords" value="yes" />
  33. <input type="hidden" name="area" value="default" />
  34. </form>
  35. </div>
  36. </div>
  37. <div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
  38. <p class="caption"><span class="caption-text">Contents:</span></p>
  39. <ul class="current">
  40. <li class="toctree-l1"><a class="reference internal" href="Installation.html">Installation</a></li>
  41. <li class="toctree-l1 current"><a class="current reference internal" href="#">What is <code class="docutils literal notranslate"><span class="pre">baangt</span></code></a><ul>
  42. <li class="toctree-l2"><a class="reference internal" href="#the-fastest-simplest-way-to-record-test-cases">The fastest, simplest way to record test cases</a></li>
  43. <li class="toctree-l2"><a class="reference internal" href="#still-simple-and-more-powerful-ways">Still simple and more powerful ways:</a><ul>
  44. <li class="toctree-l3"><a class="reference internal" href="#hey-why-not-do-everything-in-excel">Hey, why not do everything in Excel?</a></li>
  45. </ul>
  46. </li>
  47. <li class="toctree-l2"><a class="reference internal" href="#subclassing-for-multiply-used-functionality">Subclassing for multiply used functionality</a></li>
  48. <li class="toctree-l2"><a class="reference internal" href="#baangtdb-for-flexible-powerful-enterprise-grade-test-automation"><code class="docutils literal notranslate"><span class="pre">BaangtDB</span></code> for flexible, powerful enterprise grade test automation</a></li>
  49. <li class="toctree-l2"><a class="reference internal" href="#to-sum-it-up">To sum it up</a></li>
  50. </ul>
  51. </li>
  52. <li class="toctree-l1"><a class="reference internal" href="simpleExample.html">Jump-start into worry free production deployments</a></li>
  53. <li class="toctree-l1"><a class="reference internal" href="Structure.html">Structure of baangt</a></li>
  54. <li class="toctree-l1"><a class="reference internal" href="ParametersConfigFile.html">Parameters in Configuration files (<code class="docutils literal notranslate"><span class="pre">globals</span></code>)</a></li>
  55. <li class="toctree-l1"><a class="reference internal" href="TestTypes.html">Types of tests</a></li>
  56. <li class="toctree-l1"><a class="reference internal" href="Developer.html">Developer guidelines for custom enhancements</a></li>
  57. <li class="toctree-l1"><a class="reference internal" href="HistoryAndReasons.html">Why <code class="docutils literal notranslate"><span class="pre">baangt</span></code> and why is it open source?</a></li>
  58. <li class="toctree-l1"><a class="reference internal" href="contributors.html">Contributions</a></li>
  59. </ul>
  60. </div>
  61. </div>
  62. </nav>
  63. <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
  64. <nav class="wy-nav-top" aria-label="top navigation">
  65. <i data-toggle="wy-nav-top" class="fa fa-bars"></i>
  66. <a href="index.html">baangt</a>
  67. </nav>
  68. <div class="wy-nav-content">
  69. <div class="rst-content">
  70. <div role="navigation" aria-label="breadcrumbs navigation">
  71. <ul class="wy-breadcrumbs">
  72. <li><a href="index.html">Docs</a> &raquo;</li>
  73. <li>What is <code class="docutils literal notranslate"><span class="pre">baangt</span></code></li>
  74. <li class="wy-breadcrumbs-aside">
  75. <a href="_sources/OverviewUsage.rst.txt" rel="nofollow"> View page source</a>
  76. </li>
  77. </ul>
  78. <hr/>
  79. </div>
  80. <div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
  81. <div itemprop="articleBody">
  82. <div class="section" id="what-is-baangt">
  83. <h1>What is <code class="docutils literal notranslate"><span class="pre">baangt</span></code><a class="headerlink" href="#what-is-baangt" title="Permalink to this headline">¶</a></h1>
  84. <p>Testing software has always been a challenging field and it’s not getting easier or simpler as overall complexity in corporate
  85. and other applications skyrockets. Release cycles in larger corporations are often long because of inefficient regression
  86. tests. Also costs of software updates, upgrades and forward development is heavily impacted by too little test coverage.</p>
  87. <p><strong>To stop praying when you release to production you need to start serious testing!</strong></p>
  88. <p>With <code class="docutils literal notranslate"><span class="pre">baangt</span></code> you’ve one <em>open source</em> solution for all your test stages and needs. Be it Frontend with Webbrowser, API,
  89. graphQL, SOAP, oData or chromium related App-Tests. You’ll use one toolset, one database per stage and one reporting to
  90. see at any given moment, how your stages and applications are doing and if it’s safe to release the current state of one
  91. stage to the next.</p>
  92. <blockquote>
  93. <div><p><code class="docutils literal notranslate"><span class="pre">baangt</span></code> is optimized to be super easy to start and flexible when your demand grows.</p>
  94. </div></blockquote>
  95. <div class="section" id="the-fastest-simplest-way-to-record-test-cases">
  96. <h2>The fastest, simplest way to record test cases<a class="headerlink" href="#the-fastest-simplest-way-to-record-test-cases" title="Permalink to this headline">¶</a></h2>
  97. <p>If your requirements are pretty basic you’d start using <code class="docutils literal notranslate"><span class="pre">baangt</span></code> with a simple Excel-Sheet as source of Testcase definition and
  98. Testdata definition. This is super fast, very easy even for endusers but has limited flexibility, even though it comes packed
  99. with all features of the higher end solutions like reporting, fault tolerance, screenshots in case of errors and much more.</p>
  100. </div>
  101. <div class="section" id="still-simple-and-more-powerful-ways">
  102. <h2>Still simple and more powerful ways:<a class="headerlink" href="#still-simple-and-more-powerful-ways" title="Permalink to this headline">¶</a></h2>
  103. <p>As your requirements grow you’d have Testcase and testrun definition separately (e.g. you want to execute the same
  104. test cases on different stages of your system landscape (Pre-Quality, Final-Quality, Dev) and not for every heartbeat test
  105. you’d want to run through your 1000s of test data. Maybe you’ll have a SQL-Query in your Excel based data, which changes
  106. data records dynamically or per stage or per version, that you want to test for. Things are not so simple in this stage,
  107. but still simple enough for technically versed business department to run high quality tests on all stages by themselves.
  108. Even after the point, where you need technicians to integrate baangt with your CD/CI-Pipeline`s buildmanagement tools,
  109. the maintenance of data and test sequence can be done without ANY other tools (except Excel or OpenOffice) easily by the
  110. people who know best what to test: Your business department.</p>
  111. <div class="section" id="hey-why-not-do-everything-in-excel">
  112. <h3>Hey, why not do everything in Excel?<a class="headerlink" href="#hey-why-not-do-everything-in-excel" title="Permalink to this headline">¶</a></h3>
  113. <p>There is one serious drawback from this flexibilty: it’s <strong>change</strong>. Of course you started with 1 sheet, but later had some additional
  114. requirements and simply added a second sheet to cover those whithout changing the definitions of the first excel sheet.
  115. You’re still happy as you need both behaviours tested (imagine one test set for regional customers and another test set
  116. for customers from other countries). Great. Everything works. After having some serious problems in production and fixing
  117. those defects you decide to write a testcase to mimic a certain user behaviour (e.g. navigating back and forth multiple
  118. times, deleting and re-adding objects from a shopping chart, etc.). The basic test sequence would be still the same as in
  119. the other two cases, but for a specific card you’ll need changes. Simple. You copy one of the original sheets and adjust
  120. accordingly. You immediately sleep better because now also those cases are part of your growing regression test set. Wonderful.
  121. You continue like this for 2 months, end up with 2 or 3 datafiles and 20 test case definitions. That’s not uncommon. Also
  122. not uncommon is “<strong>Change</strong>”. For more direct communication with the endusers the AUT (Application under test) get’s enriched
  123. with a Sentry-Popup. Wonderful idea. But wait… It’s not so great after all, because now you have to update 20 test case
  124. definitions with a way to deal with the new popup. Imagine corporate environments where we have many 1.000 or many 10.000
  125. tests.</p>
  126. </div>
  127. </div>
  128. <div class="section" id="subclassing-for-multiply-used-functionality">
  129. <h2>Subclassing for multiply used functionality<a class="headerlink" href="#subclassing-for-multiply-used-functionality" title="Permalink to this headline">¶</a></h2>
  130. <p>The existing classes <code class="docutils literal notranslate"><span class="pre">baangt.TestCase.TestCaseMaster</span></code> and <code class="docutils literal notranslate"><span class="pre">baangt.TestStep.TestStepMaster</span></code> can easily be subclassed
  131. and enriched with static functionality - even when you use the Excel version of <code class="docutils literal notranslate"><span class="pre">baangt.py</span></code>. Yes, you’ll need to know
  132. some basics of powerful Python Language and most probably an IDE.</p>
  133. <p>An example could look as simple like this:</p>
  134. <div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="kn">from</span> <span class="nn">baangt.TestStep</span> <span class="kn">import</span> <span class="n">TestStepMaster</span>
  135. <span class="k">class</span> <span class="nc">myTestStep</span><span class="p">(</span><span class="n">TestStepMaster</span><span class="p">):</span>
  136. <span class="k">def</span> <span class="nf">execute</span><span class="p">():</span>
  137. <span class="bp">self</span><span class="o">.</span><span class="n">driver</span><span class="o">.</span><span class="n">goToURL</span><span class="p">(</span><span class="s2">&quot;http://www.google.com&quot;</span><span class="p">)</span>
  138. <span class="bp">self</span><span class="o">.</span><span class="n">driver</span><span class="o">.</span><span class="n">findByAndSetText</span><span class="p">(</span><span class="n">xpath</span><span class="o">=</span><span class="s1">&#39;//input[@type=&quot;text&quot;]&#39;</span><span class="p">,</span> <span class="n">value</span><span class="o">=</span><span class="s1">&#39;baangt&#39;</span><span class="p">)</span>
  139. <span class="bp">self</span><span class="o">.</span><span class="n">driver</span><span class="o">.</span><span class="n">findByAndClick</span><span class="p">(</span><span class="n">xpath</span><span class="o">=</span><span class="s1">&#39;(//input[contains(@type,&#39;</span><span class="n">submit</span><span class="s1">&#39;)])[3]&#39;</span><span class="p">)</span>
  140. </pre></div>
  141. </div>
  142. <p>That’s it. All the rest is taken care of by <code class="docutils literal notranslate"><span class="pre">baangt</span></code>. You’ll also receive a nice export file showing timing information
  143. for your TestCase.</p>
  144. <p>You can subclass any other functionality, that doesn’t fully fit your needs (IBAN-Generation, Browser-Handling, Timing)
  145. and also create your own Assertion-classes (for instance if you need to receive data from a Host-System or
  146. RFC/SOAP-Connection or any other source that is not natively supported by <code class="docutils literal notranslate"><span class="pre">baangt.py</span></code>). Of course you’d only
  147. re-implement methods, that you need to enrich and consume everything else from the framework.</p>
  148. <p>Please consider creating pull-requests if you think some of your custom implemented functionality could be useful for
  149. others.</p>
  150. </div>
  151. <div class="section" id="baangtdb-for-flexible-powerful-enterprise-grade-test-automation">
  152. <h2><code class="docutils literal notranslate"><span class="pre">BaangtDB</span></code> for flexible, powerful enterprise grade test automation<a class="headerlink" href="#baangtdb-for-flexible-powerful-enterprise-grade-test-automation" title="Permalink to this headline">¶</a></h2>
  153. <p>Enter the next stage: <code class="docutils literal notranslate"><span class="pre">baangtDB</span></code>. <code class="docutils literal notranslate"><span class="pre">baangtDB</span></code> does much more than just replace Excel as input and sequence source. BaangtDB
  154. provides modularization of your test cases. In the above example you’d maintain the Sentry-Popup exactly ONCE for all your
  155. test cases, where it applies.</p>
  156. <p>Also if you’re in a really large corporate environment, you’ll start facing problems with the XLS-Based solution as corporate
  157. governance, compliance, regulations and so on will sooner or later make it difficult to use the software in this way. Also
  158. even if you use <code class="docutils literal notranslate"><span class="pre">git</span></code> you experience problems with different versions of the Excel-Sheets - depending on your setup of course.</p>
  159. <p>But still no need invest into expensive, licensed, closed source, proprietary solutions and depend on their good will.
  160. Run <code class="docutils literal notranslate"><span class="pre">baangtDB</span></code> (for testdata and testcase sequences) in a docker container on premises or in Cloud and have the full flexibility plus
  161. comfort for free.</p>
  162. </div>
  163. <div class="section" id="to-sum-it-up">
  164. <h2>To sum it up<a class="headerlink" href="#to-sum-it-up" title="Permalink to this headline">¶</a></h2>
  165. <p>There are multiple ways to use the open source testing framework <code class="docutils literal notranslate"><span class="pre">baangt</span></code>. Each with it’s up- and downsides.</p>
  166. <table class="colwidths-given docutils align-default" id="id1">
  167. <caption><span class="caption-text">Possibilities to use <code class="docutils literal notranslate"><span class="pre">baangt</span></code></span><a class="headerlink" href="#id1" title="Permalink to this table">¶</a></caption>
  168. <colgroup>
  169. <col style="width: 100%" />
  170. </colgroup>
  171. <tbody>
  172. <tr class="row-odd"><td><p><strong>XLSX-Simple format</strong></p></td>
  173. </tr>
  174. <tr class="row-even"><td><p>to get you started the single Excel-Sheet holds test sequence and data. Fully functional, full reporting on test execution.</p></td>
  175. </tr>
  176. <tr class="row-odd"><td><p><strong>XLSX-full format</strong></p></td>
  177. </tr>
  178. <tr class="row-even"><td><p>XLSX format: more comples test run, test sequence, test case, test steps as part of testcase definition file. Separate data file.</p></td>
  179. </tr>
  180. <tr class="row-odd"><td><p><strong>baangtDB</strong></p></td>
  181. </tr>
  182. <tr class="row-even"><td><p>Complexity of XLSX-Format, but simpler maintenance in corporate environments. More and better ways to structure and reuse testcase sequences.</p></td>
  183. </tr>
  184. <tr class="row-odd"><td><p><strong>Cloud</strong></p></td>
  185. </tr>
  186. <tr class="row-even"><td><p>Same as database</p></td>
  187. </tr>
  188. <tr class="row-odd"><td><p><strong>Hosted</strong></p></td>
  189. </tr>
  190. <tr class="row-even"><td><p>Same as database</p></td>
  191. </tr>
  192. </tbody>
  193. </table>
  194. </div>
  195. </div>
  196. </div>
  197. </div>
  198. <footer>
  199. <div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
  200. <a href="simpleExample.html" class="btn btn-neutral float-right" title="Jump-start into worry free production deployments" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right"></span></a>
  201. <a href="Installation.html" class="btn btn-neutral float-left" title="Installation" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> Previous</a>
  202. </div>
  203. <hr/>
  204. <div role="contentinfo">
  205. <p>
  206. &copy; Copyright 2020, Bernhard Buhl
  207. </p>
  208. </div>
  209. Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
  210. </footer>
  211. </div>
  212. </div>
  213. </section>
  214. </div>
  215. <script type="text/javascript">
  216. jQuery(function () {
  217. SphinxRtdTheme.Navigation.enable(true);
  218. });
  219. </script>
  220. </body>
  221. </html>