|
Boost Users : |
Subject: [Boost-users] BOOST.TEST Mixing automatic and manual test registratioI
From: Manuel Maier (Manuel.Maier_at_[hidden])
Date: 2013-11-19 10:07:42
Hi,
Is it possible to mix manual and automatic test registration in
Boost,.Test.
Example:
BOOST_AUTO_TEST_SUITE( ExampleTestSuite )
BOOST_AUTO_TEST_CASE( testcase1 )
{
BOOST_TEST_MESSAGE("Test 1 in Example Test Suite");
BOOST_WARN_EQUAL(1, 1);
BOOST_REQUIRE_MESSAGE(5 > 1, "Here is an example message.
Something may be wrong");
}
BOOST_AUTO_TEST_SUITE_END()
Now I want to manually add a testcase to this testsuite.
This seems to be important for me, as there is no automatic registration
version for
BOOST_PARAM_TEST_CASE(...)
I also made a manualTestRegstration:
test_suite* TestSuiteA = BOOST_TEST_SUITE("test_suiteA");
void manualTestCaseRegistration()
{
TestSuiteA->add( &test_case );
framework::master_test_suite().add( TestSuiteA );
}
Is it possible to add a manual testcase(e.g.: test_case_b) to the
ExampleTestSuite?
Searching the internet I stumbled over following thread:
https://svn.boost.org/trac/boost/ticket/7000
But it seems to me this patch never made it to release(at least until
now).
In fact( I guess) this could/would be exactly the feature I am looking
for.
Kind Regards and thanks for help
Manuel
_____________________________________________
Manuel Maier, B. Eng.
Business Unit "Motion" / Research & Development
Bernecker + Rainer Industrie-Elektronik Ges.m.b.H.
B&R Strasse 1
5142 Eggelsberg
Austria
Tel: +43 7748 6586
Fax: +43 7748 6586 - 24
Email: manuel.maier_at_[hidden]
http://www.br-automation.com
____________________________________________________________
Firmenbuchnummer: Landesgericht Ried im Innkreis / FN 111651 v
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