Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 09:52:40

0001 //  (C) Copyright Gennadiy Rozental 2001.
0002 //  Distributed under the Boost Software License, Version 1.0.
0003 //  (See accompanying file LICENSE_1_0.txt or copy at
0004 //  http://www.boost.org/LICENSE_1_0.txt)
0005 
0006 //  See http://www.boost.org/libs/test for the library home page.
0007 //
0008 //  File        : $RCSfile$
0009 //
0010 //  Version     : $Revision: 74248 $
0011 //
0012 //  Description : toolbox implementation types and forward declarations
0013 // ***************************************************************************
0014 
0015 #ifndef BOOST_TEST_TOOLS_DETAIL_FWD_HPP_012705GER
0016 #define BOOST_TEST_TOOLS_DETAIL_FWD_HPP_012705GER
0017 
0018 // Boost.Test
0019 #include <boost/test/detail/config.hpp>
0020 #include <boost/test/utils/basic_cstring/io.hpp>
0021 
0022 // STL
0023 #include <cstddef>          // for std::size_t
0024 
0025 #include <boost/test/detail/suppress_warnings.hpp>
0026 
0027 //____________________________________________________________________________//
0028 
0029 namespace boost {
0030 namespace unit_test {
0031 
0032 class lazy_ostream;
0033 
0034 } // namespace unit_test
0035 
0036 namespace test_tools {
0037 
0038 using unit_test::const_string;
0039 class assertion_result;
0040 
0041 //____________________________________________________________________________//
0042 
0043 namespace tt_detail {
0044 
0045 inline bool dummy_cond() { return false; }
0046 
0047 // ************************************************************************** //
0048 // **************        types of supported assertions         ************** //
0049 // ************************************************************************** //
0050 
0051 //____________________________________________________________________________//
0052 
0053 enum check_type {
0054     CHECK_PRED,
0055     CHECK_MSG,
0056     CHECK_EQUAL,
0057     CHECK_NE,
0058     CHECK_LT,
0059     CHECK_LE,
0060     CHECK_GT,
0061     CHECK_GE,
0062     CHECK_CLOSE,
0063     CHECK_CLOSE_FRACTION,
0064     CHECK_SMALL,
0065     CHECK_BITWISE_EQUAL,
0066     CHECK_PRED_WITH_ARGS,
0067     CHECK_EQUAL_COLL,
0068     CHECK_BUILT_ASSERTION
0069 };
0070 
0071 //____________________________________________________________________________//
0072 
0073 // ************************************************************************** //
0074 // **************        levels of supported assertions        ************** //
0075 // ************************************************************************** //
0076 
0077 enum tool_level {
0078     WARN, CHECK, REQUIRE, PASS
0079 };
0080 
0081 //____________________________________________________________________________//
0082 
0083 // ************************************************************************** //
0084 // **************         Tools offline implementation         ************** //
0085 // ************************************************************************** //
0086 
0087 BOOST_TEST_DECL bool
0088 report_assertion( assertion_result const& pr, unit_test::lazy_ostream const& assertion_descr,
0089                   const_string file_name, std::size_t line_num,
0090                   tool_level tl, check_type ct,
0091                   std::size_t num_args, ... );
0092 
0093 //____________________________________________________________________________//
0094 
0095 BOOST_TEST_DECL assertion_result
0096 format_assertion_result( const_string expr_val, const_string details );
0097 
0098 //____________________________________________________________________________//
0099 
0100 BOOST_TEST_DECL assertion_result
0101 format_fpc_report( const_string expr_val, const_string details );
0102 
0103 //____________________________________________________________________________//
0104 
0105 BOOST_TEST_DECL bool
0106 is_defined_impl( const_string symbol_name, const_string symbol_value );
0107 
0108 //____________________________________________________________________________//
0109 
0110 BOOST_TEST_DECL assertion_result
0111 equal_impl( char const* left, char const* right );
0112 
0113 //____________________________________________________________________________//
0114 
0115 } // namespace tt_detail
0116 } // namespace test_tools
0117 } // namespace boost
0118 
0119 #include <boost/test/detail/enable_warnings.hpp>
0120 
0121 #endif // BOOST_TEST_TOOLS_DETAIL_FWD_HPP_012705GER