Salome HOME
Check result of Compute() in test and examples
[modules/smesh.git] / test / SMESH_Nut.py
index 884d7e12e760e836739beb8e58d3d19b908aa9f5..0d56b7b42c646e837c7a806f5b5f8f4d1670bd52 100644 (file)
@@ -147,7 +147,9 @@ smesh.SetName(hVolume, "MaxElementVolume_"+str(theMaxElementVolume))
 
 
 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 Nut:")
 print("Number of nodes       : ", mesh.NbNodes())