Salome HOME
Check result of Compute() in test and examples
[modules/smesh.git] / test / SMESH_mechanic.py
index ec7be0498f9459b0bd270039cad2a981417904fc..584a6c6912f6066a4303ff3748a5de7c98477378 100644 (file)
@@ -177,7 +177,9 @@ smesh.SetName(algo.GetSubMesh(), "SubMeshFace4")
 
 print("-------------------------- compute the mesh of the mechanic piece")
 
-mesh.Compute()
+isDone = mesh.Compute()
+if not isDone:
+    raise Exception("Error when computing Mesh")
 
 print("Information about the Mesh_mechanic:")
 print("Number of nodes       : ", mesh.NbNodes())