Boost logo

Boost Users :

From: Gennadiy Rozental (gennadiy.rozental_at_[hidden])
Date: 2006-07-30 05:41:57


You need to get up log level. Using CLA: --log_level=message
  "袁晓辉" <farproc_at_[hidden]> wrote in message news:4ab8749e0607300221n18c1da84x1c51c02933d72d65_at_mail.gmail.com...
  Thank you very much Gennadiy!

  But I have another problem: BOOST_MESSAGE does not work!!
  I modified test1 like following, but it does not give me the message "message goes here"!
  void test1()
  {
      BOOST_MESSAGE("message goes here");
      BOOST_CHECK(false);
  }

  On 7/30/06, Gennadiy Rozental <gennadiy.rozental_at_[hidden]> wrote:
    You registerred your test case with 1 expected error (see the 1 as a second argument in add call).

    You got 1 error as expected. So no unexpected errors is detected.

    Gennadiy

      "袁晓辉" <farproc_at_[hidden]> wrote in message news:4ab8749e0607300158r779fa69ar675e3a4ea08436f4_at_[hidden] ...
    The doc says "It(BOOST_CHECK) also increments an error count", but it seems not:

    #include <boost/test/included/unit_test_framework.hpp>
    using boost::unit_test::test_suite;

    void test1()
    {
        BOOST_CHECK(false);
    }

    test_suite*
    init_unit_test_suite( int, char* [] ) {
        test_suite* test= BOOST_TEST_SUITE( "Unit test );
        test->add( BOOST_TEST_CASE( &test1), 1);
        return test;
    }

    Output:
    -----------------------------------------------------
    Running 1 test case...
    xxx.cpp(171): error in "test1": check
    false failed

    *** No errors detected
    -----------------------------------------------------

    ps. I am using boost-1_33_1.

----------------------------------------------------------------------------

------------------------------------------------------------------------------

  _______________________________________________
  Boost-users mailing list
  Boost-users_at_[hidden]
  http://lists.boost.org/mailman/listinfo.cgi/boost-users



Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net