<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
<title>test_suite</title>
<link rel="stylesheet" href="../../../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.78.1">
<link rel="home" href="../../../../index.html" title="Chapter&#160;1.&#160;Boost.Test 1.22.0">
<link rel="up" href="../predicate_result.html" title="predicate_result">
<link rel="prev" href="test_case.html" title="test_case">
<link rel="next" href="master_test_suite_t.html" title="master_test_suite_t">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="test_case.html"><img src="../../../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../predicate_result.html"><img src="../../../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="master_test_suite_t.html"><img src="../../../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="test.reference.test_classes.predicate_result.test_suite"></a><a class="link" href="test_suite.html" title="test_suite"><code class="literal">test_suite</code></a>
</h5></div></div></div>
<p>
            The <code class="literal">test_suite</code> class represents a group of test cases
            and suites in the test tree hierarchy.
          </p>
<p>
</p>
<pre class="programlisting"><span class="keyword">namespace</span> <span class="identifier">bosot</span> <span class="special">{</span> <span class="keyword">namespace</span> <span class="identifier">unit_test</span> <span class="special">{</span>

<span class="keyword">class</span> <span class="identifier">BOOST_TEST_DECL</span> <span class="identifier">test_suite</span> <span class="special">:</span> <span class="keyword">public</span> <span class="identifier">test_unit</span> <span class="special">{</span>
<span class="keyword">public</span><span class="special">:</span>
    <span class="keyword">enum</span> <span class="special">{</span> <span class="identifier">type</span> <span class="special">=</span> <span class="identifier">tut_suite</span> <span class="special">};</span>

    <span class="comment">// Constructor</span>
    <span class="keyword">explicit</span>        <span class="identifier">test_suite</span><span class="special">(</span> <span class="identifier">const_string</span> <span class="identifier">ts_name</span> <span class="special">);</span>

    <span class="comment">// test unit list management</span>
    <span class="keyword">void</span>            <span class="identifier">add</span><span class="special">(</span> <span class="identifier">test_unit</span><span class="special">*</span> <span class="identifier">tu</span><span class="special">,</span> <span class="identifier">counter_t</span> <span class="identifier">expected_failures</span> <span class="special">=</span> <span class="number">0</span><span class="special">,</span> <span class="keyword">unsigned</span> <span class="identifier">timeout</span> <span class="special">=</span> <span class="number">0</span> <span class="special">);</span>
    <span class="keyword">void</span>            <span class="identifier">add</span><span class="special">(</span> <span class="identifier">test_unit_generator</span> <span class="keyword">const</span><span class="special">&amp;</span> <span class="identifier">gen</span><span class="special">,</span> <span class="keyword">unsigned</span> <span class="identifier">timeout</span> <span class="special">=</span> <span class="number">0</span> <span class="special">);</span>
    <span class="keyword">void</span>            <span class="identifier">remove</span><span class="special">(</span> <span class="identifier">test_unit_id</span> <span class="identifier">id</span> <span class="special">);</span>

    <span class="comment">// access methods</span>
    <span class="identifier">test_unit_id</span>    <span class="identifier">get</span><span class="special">(</span> <span class="identifier">const_string</span> <span class="identifier">tu_name</span> <span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
    <span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span>     <span class="identifier">size</span><span class="special">()</span> <span class="keyword">const</span> <span class="special">{</span> <span class="keyword">return</span> <span class="identifier">m_members</span><span class="special">.</span><span class="identifier">size</span><span class="special">();</span> <span class="special">}</span>
<span class="special">};</span>

<span class="special">}</span> <span class="special">}</span>
</pre>
<p>
          </p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright &#169; 2013 Richard Thomson<p>
        Distributed under the Boost Software License, Version 1.0. (See accompanying
        file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
      </p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="test_case.html"><img src="../../../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../predicate_result.html"><img src="../../../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="master_test_suite_t.html"><img src="../../../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>
