plain_report_formatter.hpp 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. // (C) Copyright Gennadiy Rozental 2001.
  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. // See http://www.boost.org/libs/test for the library home page.
  6. //
  7. // File : $RCSfile$
  8. //
  9. // Version : $Revision$
  10. //
  11. // Description : plain report formatter implementation
  12. // ***************************************************************************
  13. #ifndef BOOST_TEST_PLAIN_REPORT_FORMATTER_HPP_020105GER
  14. #define BOOST_TEST_PLAIN_REPORT_FORMATTER_HPP_020105GER
  15. // Boost.Test
  16. #include <boost/test/detail/global_typedef.hpp>
  17. #include <boost/test/results_reporter.hpp>
  18. #include <boost/test/detail/suppress_warnings.hpp>
  19. //____________________________________________________________________________//
  20. namespace boost {
  21. namespace unit_test {
  22. namespace output {
  23. // ************************************************************************** //
  24. // ************** plain_report_formatter ************** //
  25. // ************************************************************************** //
  26. class plain_report_formatter : public results_reporter::format {
  27. public:
  28. plain_report_formatter() : m_indent( 0 ), m_color_output( false ) {}
  29. // Formatter interface
  30. void results_report_start( std::ostream& ostr );
  31. void results_report_finish( std::ostream& ostr );
  32. void test_unit_report_start( test_unit const&, std::ostream& ostr );
  33. void test_unit_report_finish( test_unit const&, std::ostream& ostr );
  34. void do_confirmation_report( test_unit const&, std::ostream& ostr );
  35. private:
  36. // Data members
  37. counter_t m_indent;
  38. bool m_color_output;
  39. };
  40. } // namespace output
  41. } // namespace unit_test
  42. } // namespace boost
  43. #include <boost/test/detail/enable_warnings.hpp>
  44. #endif // BOOST_TEST_PLAIN_REPORT_FORMATTER_HPP_020105GER