• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 //  (C) Copyright Gennadiy Rozental 2011-2015.
2 //  Distributed under the Boost Software License, Version 1.0.
3 //  (See accompanying file LICENSE_1_0.txt or copy at
4 //  http://www.boost.org/LICENSE_1_0.txt)
5 
6 //  See http://www.boost.org/libs/test for the library home page.
7 
8 //[example_code
9 #define BOOST_TEST_MODULE example
10 #include <boost/test/included/unit_test.hpp>
11 
foo(int value)12 void foo( int value ) {
13   BOOST_TEST_CHECKPOINT("Inside foo with value '" << value << "' (should not be there)");
14 }
15 
BOOST_AUTO_TEST_CASE(test_case)16 BOOST_AUTO_TEST_CASE( test_case )
17 {
18   int* p = 0;
19 
20   BOOST_TEST_PASSPOINT();
21   ++p;
22 
23   BOOST_TEST_PASSPOINT();
24   ++p;
25 
26   BOOST_TEST_PASSPOINT();
27   foo( *p );
28 }
29 //]
30