From: cvw Date: Thu, 22 Mar 2012 10:05:16 +0000 (+0000) Subject: *** empty log message *** X-Git-Tag: V6_main_FINAL~746 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=798a0db4ba65f8b4ed31f32751148cf2af6e4b5b;p=tools%2Fmedcoupling.git *** empty log message *** --- diff --git a/src/MEDPartitioner/Test/MEDPARTITIONERTest.cxx b/src/MEDPartitioner/Test/MEDPARTITIONERTest.cxx index cbd0f63d9..cce72b8f3 100644 --- a/src/MEDPartitioner/Test/MEDPARTITIONERTest.cxx +++ b/src/MEDPartitioner/Test/MEDPARTITIONERTest.cxx @@ -89,6 +89,15 @@ void MEDPARTITIONERTest::setbigSize() void MEDPARTITIONERTest::setUp() { this->_verbose=0; +#if defined(HAVE_MPI2) + MPI_Init(0,0) + MPI_Comm_size(MPI_COMM_WORLD, &MyGlobals::_World_Size); + MPI_Comm_rank(MPI_COMM_WORLD, &MyGlobals::_Rank); +#else + //sequential : no MPI + MyGlobals::_World_Size=1; + MyGlobals::_Rank=0; +#endif } // ============================================================================ diff --git a/src/MEDPartitioner/Test/MEDPARTITIONERTestPara.cxx b/src/MEDPartitioner/Test/MEDPARTITIONERTestPara.cxx index 75b1d688e..f7ff89290 100644 --- a/src/MEDPartitioner/Test/MEDPARTITIONERTestPara.cxx +++ b/src/MEDPartitioner/Test/MEDPARTITIONERTestPara.cxx @@ -71,10 +71,6 @@ void MEDPARTITIONERTest::verifyMedpartitionerOnSmallSizeForMesh() CPPUNIT_ASSERT_EQUAL(0, res); input=targetName+".xml"; - MPI_Init(0,0); - MPI_Comm_size(MPI_COMM_WORLD, &MyGlobals::_World_Size); - MPI_Comm_rank(MPI_COMM_WORLD, &MyGlobals::_Rank); - MEDPARTITIONER::ParaDomainSelector parallelizer(false); MEDPARTITIONER::MeshCollection collection(input,parallelizer); CPPUNIT_ASSERT_EQUAL(3, collection.getMeshDimension());