From: michael Date: Fri, 10 Dec 2021 13:28:10 +0000 (+0100) Subject: Updated expected values in python unit tests X-Git-Tag: V9_8_0~16 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=94ba913663004ada6ee4653d9323db57849a550c;p=tools%2Fsolverlab.git Updated expected values in python unit tests --- diff --git a/CDMATH/tests/swig/mainTests.py b/CDMATH/tests/swig/mainTests.py index 9bad2be..aa8e938 100755 --- a/CDMATH/tests/swig/mainTests.py +++ b/CDMATH/tests/swig/mainTests.py @@ -471,15 +471,20 @@ class TestsCDMATHSwig(unittest.TestCase): self.assertTrue(y11 == 0.0) M1.setGroupAtFaceByCoords(0., 0., 0., 1.E-14, "LeftEdge") M1.setGroupAtFaceByCoords(4., 0., 0., 1.E-14, "RightEdge") + M1.setGroupAtNodeByCoords(0., 0., 0., 1.E-14, "LeftEdge") + M1.setGroupAtNodeByCoords(4., 0., 0., 1.E-14, "RightEdge") self.assertTrue(M1.getFace(0).isBorder() == True) self.assertTrue(M1.getFace(1).isBorder() == False) self.assertTrue(M1.getFace(2).isBorder() == False) self.assertTrue(M1.getFace(3).isBorder() == False) self.assertTrue(M1.getFace(4).isBorder() == True) self.assertTrue(len(M1.getNameOfFaceGroups()) ==3) - self.assertTrue(M1.getNameOfFaceGroups()[0] == "RightEdge") + self.assertTrue(M1.getNameOfFaceGroups()[2] == "RightEdge") self.assertTrue(M1.getNameOfFaceGroups()[1] == "LeftEdge") - self.assertTrue(M1.getNameOfFaceGroups()[2] == "Boundary") + self.assertTrue(M1.getNameOfFaceGroups()[0] == "Boundary") + self.assertTrue(M1.getNameOfNodeGroups()[2] == "RightEdge") + self.assertTrue(M1.getNameOfNodeGroups()[1] == "LeftEdge") + self.assertTrue(M1.getNameOfNodeGroups()[0] == "Boundary") M1 = Mesh(0.0, 1.0, 4) self.assertTrue(1 == M1.getSpaceDimension()) @@ -514,7 +519,11 @@ class TestsCDMATHSwig(unittest.TestCase): M2.setGroupAtPlan(yinf, 1, eps, "BottomEdge") M2.setGroupAtPlan(ysup, 1, eps, "TopEdge") self.assertTrue(len(M2.getNameOfFaceGroups()) == 5) - self.assertTrue(M2.getNameOfFaceGroups()[1] == "BottomEdge") + self.assertTrue(M2.getNameOfFaceGroups()[0] == "Boundary") + self.assertTrue(M2.getNameOfFaceGroups()[1] == "RightEdge") + self.assertTrue(M2.getNameOfFaceGroups()[2] == "LeftEdge") + self.assertTrue(M2.getNameOfFaceGroups()[3] == "BottomEdge") + self.assertTrue(M2.getNameOfFaceGroups()[4] == "TopEdge") nbFaces = M2.getNumberOfFaces() M2.setPeriodicFaces() indexFaces = M2.getIndexFacePeriodic() @@ -544,10 +553,11 @@ class TestsCDMATHSwig(unittest.TestCase): M23 = Mesh("meshSquare.med") self.assertTrue(len(M23.getNameOfFaceGroups()) == 5) print( M23.getNameOfFaceGroups() ) - self.assertTrue(M23.getNameOfFaceGroups()[3] == "Bottom") + self.assertTrue(M23.getNameOfFaceGroups()[1] == "Bottom") self.assertTrue(M23.getNameOfFaceGroups()[2] == "Left") - self.assertTrue(M23.getNameOfFaceGroups()[1] == "Right") - self.assertTrue(M23.getNameOfFaceGroups()[0] == "Top") + self.assertTrue(M23.getNameOfFaceGroups()[3] == "Right") + self.assertTrue(M23.getNameOfFaceGroups()[4] == "Top") + self.assertTrue(M23.getNameOfFaceGroups()[0] == "Boundary") M3 = M1 self.assertTrue(1 == M3.getSpaceDimension())