Salome HOME
Mise à la norme python des fichiers
[modules/smesh.git] / src / Tools / blocFissure / CasTests / faceGauche_2.py
index c9e0e0fbce12eb35505d0811c8b088fbeacf48ed..4bcc36494d01b656ec409ed73c7964d9a8956c26 100644 (file)
@@ -1,4 +1,22 @@
 # -*- coding: utf-8 -*-
+# Copyright (C) 2014-2020  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
+#
 
 import os
 from blocFissure import gmu
@@ -24,17 +42,15 @@ from blocFissure.gmu.construitFissureGenerale import construitFissureGenerale
 O, OX, OY, OZ = triedreBase()
 
 class faceGauche_2(fissureGenerique):
-  """
-  problème de fissure non plane, débouchante non normale
-  """
+  """problème de fissure non plane, débouchante non normale"""
 
-  nomProbleme = "faceGauche2"
+  nomProbleme = "faceGauche_2"
 
   # ---------------------------------------------------------------------------
   def genereMaillageSain(self, geometriesSaines, meshParams):
     logging.info("genereMaillageSain %s", self.nomCas)
 
-    ([objetSain], status) = smesh.CreateMeshesFromMED(os.path.join(gmu.pathBloc, "materielCasTests/boiteSaine.med"))
+    ([objetSain], status) = smesh.CreateMeshesFromMED(os.path.join(gmu.pathBloc, "materielCasTests", "boiteSaine.med"))
     smesh.SetName(objetSain.GetMesh(), 'objetSain')
 
     return [objetSain, True] # True : maillage hexa
@@ -58,9 +74,9 @@ class faceGauche_2(fissureGenerique):
 
     lgInfluence = shapeFissureParams['lgInfluence']
 
-    shellFiss = geompy.ImportFile(os.path.join(gmu.pathBloc, "materielCasTests/faceGauche2FissCoupe.brep"), "BREP")
+    shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests", "faceGauche2FissCoupe.brep"))
     fondFiss = geompy.CreateGroup(shellFiss, geompy.ShapeType["EDGE"])
-    geompy.UnionIDs(fondFiss, [12, 4])
+    geompy.UnionIDs(fondFiss, [14, 9])
     geompy.addToStudy( shellFiss, 'shellFiss' )
     geompy.addToStudyInFather( shellFiss, fondFiss, 'fondFiss' )
 
@@ -95,12 +111,14 @@ class faceGauche_2(fissureGenerique):
 
   # ---------------------------------------------------------------------------
   def setReferencesMaillageFissure(self):
-    self.referencesMaillageFissure = dict(Entity_Quad_Pyramid    = 859,
+    self.referencesMaillageFissure = dict( \
+                                          Entity_Quad_Pyramid    = 859,
                                           Entity_Quad_Triangle   = 634,
                                           Entity_Quad_Edge       = 323,
                                           Entity_Quad_Penta      = 288,
                                           Entity_Quad_Hexa       = 3435,
                                           Entity_Node            = 44095,
                                           Entity_Quad_Tetra      = 18400,
-                                          Entity_Quad_Quadrangle = 2542)
+                                          Entity_Quad_Quadrangle = 2542
+                                         )