File: unit_test_example1.html

package info (click to toggle)
boost 1.34.1-14
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 116,412 kB
  • ctags: 259,566
  • sloc: cpp: 642,395; xml: 56,450; python: 17,612; ansic: 14,520; sh: 2,265; yacc: 858; perl: 481; makefile: 478; lex: 94; sql: 74; csh: 6
file content (54 lines) | stat: -rw-r--r-- 2,540 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<HTML>
<HEAD>
<TITLE>Boost Test Library: unit_test_example1 example</TITLE>
<LINK rel="stylesheet" type="text/css" href="../style/btl.css" media="screen">
<LINK rel="stylesheet" type="text/css" href="../style/btl-print.css" media="print">
<META http-equiv="Content-Language" content="en-us">
<META http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</HEAD>
<BODY>
<DIV class="header"> <A href="../index.html">Boost.Test</A> &gt; <A href="index.html">Examples</A> &gt; <SPAN class="current_article">unit_test_example1</SPAN> 
</DIV>
<DIV class="body"> <IMG src="../btl1.gif" width="252" height="43" alt="Boost Test logo"> 
  <H1 class="subtitle">The Unit Test Framework example 1</H1>
  <TABLE class="test-example-summary">
    <TR>
      <TD class="title" valign="top">Rationale:</TD>
      <TD>this simple introductory example demonstrate several basic concepts of the Unit Test Framework: 
        <UL>
          <LI>usage of init_unit_test_framework to create and initialize test suite</LI>
          <LI>test case creation based on free function</LI>
          <LI>usage of basic test tools in test case</LI>
          <LI>usage of &quot;number of expected failures&quot; feature </LI>
        </UL>
      </TD>
    </TR>
    <TR>
      <TD class="title" valign="top">Input:</TD>
      <TD>This example does not require any input</TD>
    </TR>
    <TR>
      <TD class="title" valign="top">Output:</TD>
      <TD><SPAN class="test-output">Running 1 test case...<BR>
        .../unit_test_example1.cpp(17): error in &quot;free_test_function&quot;: test 2 == 1 failed<BR>
        <BR>
        *** No errors detected </SPAN> </TD>
    </TR>
    <TR>
      <TD class="title" valign="top">Source:</TD>
      <TD><A href="../../example/unit_test_example1.cpp">unit_test_example1.cpp</A></TD>
    </TR>
  </TABLE>
</DIV>
<DIV class="footer"> 
  <DIV class="footer-body"> 
    <P> &copy; <A name="Copyright">Copyright</A> <A href="mailto:boost-test%20at%20emailaccount%20dot%20com%20%28please%20unobscure%29">Gennadiy Rozental</A> 2001-2006. <BR>
      Distributed under the Boost Software License, Version 1.0.
      (See accompanying file <A href="../../../../LICENSE_1_0.txt">LICENSE_1_0.txt</A> or copy at 
      <A href="http://www.boost.org/LICENSE_1_0.txt">www.boost.org/LICENSE_1_0.txt</A>)</P>
        <P>Revised:        <!-- #BeginDate format:Sw1 -->28 February, 2006<!-- #EndDate -->     </P>
  </DIV>
</DIV>
</BODY>
</HTML>