Salome HOME
Update copyrights
[modules/smesh.git] / src / Tools / ZCracksPlug / casTests / launchCas.py
index 3522ee67e1583d24a2107b1a8e9d3a928c95b5fd..b84cfc28873ce5efde2f4fa2deef36b6b129e5c4 100644 (file)
@@ -1,3 +1,21 @@
+# Copyright (C) 2016-2019  CEA/DEN, EDF R&D
+#
+# This library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License as published by the Free Software Foundation; either
+# version 2.1 of the License, or (at your option) any later version.
+#
+# This library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public
+# License along with this library; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
+#
+# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+#
 
 from Zcracks import genereCrack, Zset
 from Zcracks import utilityFunctions as uF
@@ -18,13 +36,13 @@ import string
 
 #tmpdir = "/local00/home/B27118/projets/Zcracks/Zcracks/casTests/tmpdir"
 #if not os.path.isdir(tmpdir): os.mkdir(tmpdir)
-tmpdir=tempfile.mktemp(prefix='tmpZcracks')
+tmpdir=tempfile.mkdtemp(prefix='tmpZcracks')
 print("tmpdir=", tmpdir)
 
-meshgemsdir=os.environ('MESHGEMSHOME')
-if len(meshgemsdir) > 0:
-  meshgems=string.split(meshgemsdir,os.sep)[-1]
-  uF.removeFromSessionPath('LD_LIBRARY_PATH', meshgems)
+#meshgemsdir=os.environ('MESHGEMSHOME')
+#if len(meshgemsdir) > 0:
+  #meshgems=string.split(meshgemsdir,os.sep)[-1]
+  #uF.removeFromSessionPath('LD_LIBRARY_PATH', meshgems)
 
 def LAUNCH(listCas=[]):
   if not isinstance(listCas, list): listCas=[listCas]
@@ -194,7 +212,7 @@ def LAUNCH(listCas=[]):
 
   OK=[]
   NOOK=[]
-  for s in list(synthese.keys()):
+  for s in synthese:
     if synthese[s]:
       OK.append(s)
     else: