Sophie

Sophie

distrib > Mageia > 7 > armv7hl > media > core-updates > by-pkgid > bf9e3bc1aec7873c087fb2ccd927873f > files > 123

sdl2-docs-2.0.10-1.mga7.noarch.rpm

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.15"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>My Project: SDL_test_harness.h Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">My Project
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.15 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="headertitle">
<div class="title">SDL_test_harness.h</div>  </div>
</div><!--header-->
<div class="contents">
<a href="SDL__test__harness_8h.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="comment">/*</span></div><div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="comment">  Simple DirectMedia Layer</span></div><div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;<span class="comment">  Copyright (C) 1997-2019 Sam Lantinga &lt;slouken@libsdl.org&gt;</span></div><div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="comment"></span></div><div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;<span class="comment">  This software is provided &#39;as-is&#39;, without any express or implied</span></div><div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="comment">  warranty.  In no event will the authors be held liable for any damages</span></div><div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="comment">  arising from the use of this software.</span></div><div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="comment"></span></div><div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="comment">  Permission is granted to anyone to use this software for any purpose,</span></div><div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="comment">  including commercial applications, and to alter it and redistribute it</span></div><div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;<span class="comment">  freely, subject to the following restrictions:</span></div><div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;<span class="comment"></span></div><div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;<span class="comment">  1. The origin of this software must not be misrepresented; you must not</span></div><div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;<span class="comment">     claim that you wrote the original software. If you use this software</span></div><div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;<span class="comment">     in a product, an acknowledgment in the product documentation would be</span></div><div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160;<span class="comment">     appreciated but is not required.</span></div><div class="line"><a name="l00017"></a><span class="lineno">   17</span>&#160;<span class="comment">  2. Altered source versions must be plainly marked as such, and must not be</span></div><div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160;<span class="comment">     misrepresented as being the original software.</span></div><div class="line"><a name="l00019"></a><span class="lineno">   19</span>&#160;<span class="comment">  3. This notice may not be removed or altered from any source distribution.</span></div><div class="line"><a name="l00020"></a><span class="lineno">   20</span>&#160;<span class="comment">*/</span></div><div class="line"><a name="l00021"></a><span class="lineno">   21</span>&#160;</div><div class="line"><a name="l00030"></a><span class="lineno">   30</span>&#160;<span class="comment">/*</span></div><div class="line"><a name="l00031"></a><span class="lineno">   31</span>&#160;<span class="comment">  Defines types for test case definitions and the test execution harness API.</span></div><div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160;<span class="comment"></span></div><div class="line"><a name="l00033"></a><span class="lineno">   33</span>&#160;<span class="comment">  Based on original GSOC code by Markus Kauppila &lt;markus.kauppila@gmail.com&gt;</span></div><div class="line"><a name="l00034"></a><span class="lineno">   34</span>&#160;<span class="comment">*/</span></div><div class="line"><a name="l00035"></a><span class="lineno">   35</span>&#160;</div><div class="line"><a name="l00036"></a><span class="lineno">   36</span>&#160;<span class="preprocessor">#ifndef SDL_test_h_arness_h</span></div><div class="line"><a name="l00037"></a><span class="lineno">   37</span>&#160;<span class="preprocessor">#define SDL_test_h_arness_h</span></div><div class="line"><a name="l00038"></a><span class="lineno">   38</span>&#160;</div><div class="line"><a name="l00039"></a><span class="lineno">   39</span>&#160;<span class="preprocessor">#include &quot;<a class="code" href="begin__code_8h.html">begin_code.h</a>&quot;</span></div><div class="line"><a name="l00040"></a><span class="lineno">   40</span>&#160;<span class="comment">/* Set up for C function definitions, even when using C++ */</span></div><div class="line"><a name="l00041"></a><span class="lineno">   41</span>&#160;<span class="preprocessor">#ifdef __cplusplus</span></div><div class="line"><a name="l00042"></a><span class="lineno">   42</span>&#160;<span class="keyword">extern</span> <span class="stringliteral">&quot;C&quot;</span> {</div><div class="line"><a name="l00043"></a><span class="lineno">   43</span>&#160;<span class="preprocessor">#endif</span></div><div class="line"><a name="l00044"></a><span class="lineno">   44</span>&#160;</div><div class="line"><a name="l00045"></a><span class="lineno">   45</span>&#160;</div><div class="line"><a name="l00046"></a><span class="lineno">   46</span>&#160;<span class="comment">/* ! Definitions for test case structures */</span></div><div class="line"><a name="l00047"></a><span class="lineno">   47</span>&#160;<span class="preprocessor">#define TEST_ENABLED  1</span></div><div class="line"><a name="l00048"></a><span class="lineno">   48</span>&#160;<span class="preprocessor">#define TEST_DISABLED 0</span></div><div class="line"><a name="l00049"></a><span class="lineno">   49</span>&#160;</div><div class="line"><a name="l00050"></a><span class="lineno">   50</span>&#160;<span class="comment">/* ! Definition of all the possible test return values of the test case method */</span></div><div class="line"><a name="l00051"></a><span class="lineno">   51</span>&#160;<span class="preprocessor">#define TEST_ABORTED        -1</span></div><div class="line"><a name="l00052"></a><span class="lineno">   52</span>&#160;<span class="preprocessor">#define TEST_STARTED         0</span></div><div class="line"><a name="l00053"></a><span class="lineno">   53</span>&#160;<span class="preprocessor">#define TEST_COMPLETED       1</span></div><div class="line"><a name="l00054"></a><span class="lineno">   54</span>&#160;<span class="preprocessor">#define TEST_SKIPPED         2</span></div><div class="line"><a name="l00055"></a><span class="lineno">   55</span>&#160;</div><div class="line"><a name="l00056"></a><span class="lineno">   56</span>&#160;<span class="comment">/* ! Definition of all the possible test results for the harness */</span></div><div class="line"><a name="l00057"></a><span class="lineno">   57</span>&#160;<span class="preprocessor">#define TEST_RESULT_PASSED              0</span></div><div class="line"><a name="l00058"></a><span class="lineno">   58</span>&#160;<span class="preprocessor">#define TEST_RESULT_FAILED              1</span></div><div class="line"><a name="l00059"></a><span class="lineno">   59</span>&#160;<span class="preprocessor">#define TEST_RESULT_NO_ASSERT           2</span></div><div class="line"><a name="l00060"></a><span class="lineno">   60</span>&#160;<span class="preprocessor">#define TEST_RESULT_SKIPPED             3</span></div><div class="line"><a name="l00061"></a><span class="lineno">   61</span>&#160;<span class="preprocessor">#define TEST_RESULT_SETUP_FAILURE       4</span></div><div class="line"><a name="l00062"></a><span class="lineno">   62</span>&#160;</div><div class="line"><a name="l00063"></a><span class="lineno">   63</span>&#160;<span class="comment">/* !&lt; Function pointer to a test case setup function (run before every test) */</span></div><div class="line"><a name="l00064"></a><span class="lineno">   64</span>&#160;<span class="keyword">typedef</span> void (*SDLTest_TestCaseSetUpFp)(<span class="keywordtype">void</span> *arg);</div><div class="line"><a name="l00065"></a><span class="lineno">   65</span>&#160;</div><div class="line"><a name="l00066"></a><span class="lineno">   66</span>&#160;<span class="comment">/* !&lt; Function pointer to a test case function */</span></div><div class="line"><a name="l00067"></a><span class="lineno">   67</span>&#160;<span class="keyword">typedef</span> int (*SDLTest_TestCaseFp)(<span class="keywordtype">void</span> *arg);</div><div class="line"><a name="l00068"></a><span class="lineno">   68</span>&#160;</div><div class="line"><a name="l00069"></a><span class="lineno">   69</span>&#160;<span class="comment">/* !&lt; Function pointer to a test case teardown function (run after every test) */</span></div><div class="line"><a name="l00070"></a><span class="lineno">   70</span>&#160;<span class="keyword">typedef</span> void  (*SDLTest_TestCaseTearDownFp)(<span class="keywordtype">void</span> *arg);</div><div class="line"><a name="l00071"></a><span class="lineno">   71</span>&#160;</div><div class="line"><a name="l00075"></a><span class="lineno"><a class="line" href="structSDLTest__TestCaseReference.html">   75</a></span>&#160;<span class="keyword">typedef</span> <span class="keyword">struct </span><a class="code" href="structSDLTest__TestCaseReference.html">SDLTest_TestCaseReference</a> {</div><div class="line"><a name="l00076"></a><span class="lineno">   76</span>&#160;    <span class="comment">/* !&lt; Func2Stress */</span></div><div class="line"><a name="l00077"></a><span class="lineno">   77</span>&#160;    SDLTest_TestCaseFp testCase;</div><div class="line"><a name="l00078"></a><span class="lineno">   78</span>&#160;    <span class="comment">/* !&lt; Short name (or function name) &quot;Func2Stress&quot; */</span></div><div class="line"><a name="l00079"></a><span class="lineno">   79</span>&#160;    <span class="keywordtype">char</span> *name;</div><div class="line"><a name="l00080"></a><span class="lineno">   80</span>&#160;    <span class="comment">/* !&lt; Long name or full description &quot;This test pushes func2() to the limit.&quot; */</span></div><div class="line"><a name="l00081"></a><span class="lineno">   81</span>&#160;    <span class="keywordtype">char</span> *description;</div><div class="line"><a name="l00082"></a><span class="lineno">   82</span>&#160;    <span class="comment">/* !&lt; Set to TEST_ENABLED or TEST_DISABLED (test won&#39;t be run) */</span></div><div class="line"><a name="l00083"></a><span class="lineno">   83</span>&#160;    <span class="keywordtype">int</span> enabled;</div><div class="line"><a name="l00084"></a><span class="lineno">   84</span>&#160;} <a class="code" href="SDL__test__harness_8h.html#a80ea4f56022704ad5ca88f045ca90647">SDLTest_TestCaseReference</a>;</div><div class="line"><a name="l00085"></a><span class="lineno">   85</span>&#160;</div><div class="line"><a name="l00089"></a><span class="lineno"><a class="line" href="structSDLTest__TestSuiteReference.html">   89</a></span>&#160;<span class="keyword">typedef</span> <span class="keyword">struct </span><a class="code" href="structSDLTest__TestSuiteReference.html">SDLTest_TestSuiteReference</a> {</div><div class="line"><a name="l00090"></a><span class="lineno">   90</span>&#160;    <span class="comment">/* !&lt; &quot;PlatformSuite&quot; */</span></div><div class="line"><a name="l00091"></a><span class="lineno">   91</span>&#160;    <span class="keywordtype">char</span> *name;</div><div class="line"><a name="l00092"></a><span class="lineno">   92</span>&#160;    <span class="comment">/* !&lt; The function that is run before each test. NULL skips. */</span></div><div class="line"><a name="l00093"></a><span class="lineno">   93</span>&#160;    SDLTest_TestCaseSetUpFp testSetUp;</div><div class="line"><a name="l00094"></a><span class="lineno">   94</span>&#160;    <span class="comment">/* !&lt; The test cases that are run as part of the suite. Last item should be NULL. */</span></div><div class="line"><a name="l00095"></a><span class="lineno">   95</span>&#160;    <span class="keyword">const</span> <a class="code" href="structSDLTest__TestCaseReference.html">SDLTest_TestCaseReference</a> **testCases;</div><div class="line"><a name="l00096"></a><span class="lineno">   96</span>&#160;    <span class="comment">/* !&lt; The function that is run after each test. NULL skips. */</span></div><div class="line"><a name="l00097"></a><span class="lineno">   97</span>&#160;    SDLTest_TestCaseTearDownFp testTearDown;</div><div class="line"><a name="l00098"></a><span class="lineno">   98</span>&#160;} <a class="code" href="SDL__test__harness_8h.html#ac9f9cb01c6801359e407bd49723f8e7c">SDLTest_TestSuiteReference</a>;</div><div class="line"><a name="l00099"></a><span class="lineno">   99</span>&#160;</div><div class="line"><a name="l00100"></a><span class="lineno">  100</span>&#160;</div><div class="line"><a name="l00110"></a><span class="lineno">  110</span>&#160;<span class="keywordtype">char</span> *<a class="code" href="SDL__test__harness_8h.html#a0f3c803e79549fcfd3bec2e93b19e0b1">SDLTest_GenerateRunSeed</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> length);</div><div class="line"><a name="l00111"></a><span class="lineno">  111</span>&#160;</div><div class="line"><a name="l00123"></a><span class="lineno">  123</span>&#160;<span class="keywordtype">int</span> <a class="code" href="SDL__test__harness_8h.html#a4999be460499b1cb45e2b2b3bbb582b2">SDLTest_RunSuites</a>(<a class="code" href="structSDLTest__TestSuiteReference.html">SDLTest_TestSuiteReference</a> *testSuites[], <span class="keyword">const</span> <span class="keywordtype">char</span> *userRunSeed, Uint64 userExecKey, <span class="keyword">const</span> <span class="keywordtype">char</span> *filter, <span class="keywordtype">int</span> testIterations);</div><div class="line"><a name="l00124"></a><span class="lineno">  124</span>&#160;</div><div class="line"><a name="l00125"></a><span class="lineno">  125</span>&#160;</div><div class="line"><a name="l00126"></a><span class="lineno">  126</span>&#160;<span class="comment">/* Ends C function definitions when using C++ */</span></div><div class="line"><a name="l00127"></a><span class="lineno">  127</span>&#160;<span class="preprocessor">#ifdef __cplusplus</span></div><div class="line"><a name="l00128"></a><span class="lineno">  128</span>&#160;}</div><div class="line"><a name="l00129"></a><span class="lineno">  129</span>&#160;<span class="preprocessor">#endif</span></div><div class="line"><a name="l00130"></a><span class="lineno">  130</span>&#160;<span class="preprocessor">#include &quot;<a class="code" href="close__code_8h.html">close_code.h</a>&quot;</span></div><div class="line"><a name="l00131"></a><span class="lineno">  131</span>&#160;</div><div class="line"><a name="l00132"></a><span class="lineno">  132</span>&#160;<span class="preprocessor">#endif </span><span class="comment">/* SDL_test_h_arness_h */</span><span class="preprocessor"></span></div><div class="line"><a name="l00133"></a><span class="lineno">  133</span>&#160;</div><div class="line"><a name="l00134"></a><span class="lineno">  134</span>&#160;<span class="comment">/* vi: set ts=4 sw=4 expandtab: */</span></div><div class="ttc" id="SDL__test__harness_8h_html_a80ea4f56022704ad5ca88f045ca90647"><div class="ttname"><a href="SDL__test__harness_8h.html#a80ea4f56022704ad5ca88f045ca90647">SDLTest_TestCaseReference</a></div><div class="ttdeci">struct SDLTest_TestCaseReference SDLTest_TestCaseReference</div></div>
<div class="ttc" id="SDL__test__harness_8h_html_a4999be460499b1cb45e2b2b3bbb582b2"><div class="ttname"><a href="SDL__test__harness_8h.html#a4999be460499b1cb45e2b2b3bbb582b2">SDLTest_RunSuites</a></div><div class="ttdeci">int SDLTest_RunSuites(SDLTest_TestSuiteReference *testSuites[], const char *userRunSeed, Uint64 userExecKey, const char *filter, int testIterations)</div><div class="ttdoc">Execute a test suite using the given run seed and execution key.</div></div>
<div class="ttc" id="begin__code_8h_html"><div class="ttname"><a href="begin__code_8h.html">begin_code.h</a></div></div>
<div class="ttc" id="structSDLTest__TestCaseReference_html"><div class="ttname"><a href="structSDLTest__TestCaseReference.html">SDLTest_TestCaseReference</a></div><div class="ttdef"><b>Definition:</b> SDL_test_harness.h:75</div></div>
<div class="ttc" id="close__code_8h_html"><div class="ttname"><a href="close__code_8h.html">close_code.h</a></div></div>
<div class="ttc" id="structSDLTest__TestSuiteReference_html"><div class="ttname"><a href="structSDLTest__TestSuiteReference.html">SDLTest_TestSuiteReference</a></div><div class="ttdef"><b>Definition:</b> SDL_test_harness.h:89</div></div>
<div class="ttc" id="SDL__test__harness_8h_html_a0f3c803e79549fcfd3bec2e93b19e0b1"><div class="ttname"><a href="SDL__test__harness_8h.html#a0f3c803e79549fcfd3bec2e93b19e0b1">SDLTest_GenerateRunSeed</a></div><div class="ttdeci">char * SDLTest_GenerateRunSeed(const int length)</div><div class="ttdoc">Generates a random run seed string for the harness. The generated seed will contain alphanumeric char...</div></div>
<div class="ttc" id="SDL__test__harness_8h_html_ac9f9cb01c6801359e407bd49723f8e7c"><div class="ttname"><a href="SDL__test__harness_8h.html#ac9f9cb01c6801359e407bd49723f8e7c">SDLTest_TestSuiteReference</a></div><div class="ttdeci">struct SDLTest_TestSuiteReference SDLTest_TestSuiteReference</div></div>
</div><!-- fragment --></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.15
</small></address>
</body>
</html>