Boost logo

Boost :

Subject: [boost] Unit test custom runner
From: Emy (emilie.deschamps_at_[hidden])
Date: 2011-03-10 15:27:17


Hi,

I am trying to unit test my project with boost. Working in visual studio,
what I have now is a solution (sln) with many projects. Importants one are a
lib (the project I want to test) and a other one is a project for my unit
test (exe).

At first, I wanted to use "BOOST_TEST_MAIN" in my UnitTest project. But
because of our solution architecture, the entry point of each project isn't
"main( int argc, char* argv[] )", but have a custom name ("InitMain( int
argc, char* argv[] )").

Because of that custom name, even when I set my unitTest project as the
start up project, it doesn't work using BOOST_TEST_MAIN (because it's not
the main called first, but InitMain).

Is there a way to use macros (BOOST_AUTO_TEST_CASE, etc...) and the
unit_test_main (to process some console arguments), but having a custom
entry point (in my case, InitMain) instead of main ?

Thank you !

Emilie

--
View this message in context: http://boost.2283326.n4.nabble.com/Unit-test-custom-runner-tp3346717p3346717.html
Sent from the Boost - Dev mailing list archive at Nabble.com.

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk