]> SALOME platform Git repositories - modules/kernel.git/commitdiff
Salome HOME
Improved the process of launching the Salome
authorsrn <srn@opencascade.com>
Wed, 13 Dec 2006 11:52:56 +0000 (11:52 +0000)
committersrn <srn@opencascade.com>
Wed, 13 Dec 2006 11:52:56 +0000 (11:52 +0000)
src/SALOMEDS/Test/TestSALOMEDS.cxx

index 9ea70bac35137c83fd0f6ccfc35b650f090939e6..dc7c874dbe92e9189cfcf336f54a9a2a125561e6 100644 (file)
@@ -48,6 +48,7 @@ CPPUNIT_TEST_SUITE_REGISTRATION( SALOMEDSTest_Embedded );
 #include "utilities.h"
 #include "Utils_SINGLETON.hxx"
 #include "Utils_ORB_INIT.hxx"
+#include "OpUtil.hxx"
 #include "SALOME_NamingService.hxx"
 #include "NamingService_WaitForServerReadiness.hxx"
 #include "SALOMEDS_StudyManager_i.hxx"
@@ -85,8 +86,15 @@ int main(int argc, char* argv[])
 
   sleep(10);
 
+  string host = GetHostname();
+
   SALOME_NamingService NS(orb);
-  NamingService_WaitForServerReadiness(&NS, "/myStudyManager");
+  if(host.empty())
+    NamingService_WaitForServerReadiness(&NS, "/myStudyManager");
+  else {
+    string serverName = "/Containers/"+host+"/SuperVisionContainer";
+    NamingService_WaitForServerReadiness(&NS, serverName);
+  }
 
   CORBA::Object_var obj = NS.Resolve( "/myStudyManager" );
   if(CORBA::is_nil(obj)) {