X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FSketchPlugin%2FTest%2FTestConstraintVertical.py;h=1fe6af2722b3759595e30bf056f4f6eab329a8d1;hb=256f2a6c7f3d72659a0378be0116c745dfc13dc2;hp=8bbc541cd94b15fc4e32e04668dcfc36a0acee3b;hpb=5b6031b015602aa07f5a6fc668c13ac3faf7a8a9;p=modules%2Fshaper.git diff --git a/src/SketchPlugin/Test/TestConstraintVertical.py b/src/SketchPlugin/Test/TestConstraintVertical.py index 8bbc541cd..1fe6af272 100644 --- a/src/SketchPlugin/Test/TestConstraintVertical.py +++ b/src/SketchPlugin/Test/TestConstraintVertical.py @@ -9,6 +9,8 @@ """ from GeomDataAPI import * from ModelAPI import * +from salome.shaper import model + #========================================================================= # Initialization of the test #========================================================================= @@ -40,6 +42,7 @@ aLineEndPoint = geomDataAPI_Point2D(aSketchLine.attribute("EndPoint")) aLineStartPoint.setValue(0., 15.) aLineEndPoint.setValue(20., 25.) aSession.finishOperation() +assert (model.dof(aSketchFeature) == 4) #========================================================================= # Assign vertical constraint for a line #========================================================================= @@ -52,6 +55,7 @@ refattrA.setObject(aResult) aVerticalConstraint.execute() aSession.finishOperation() assert(aLineStartPoint.x() == aLineEndPoint.x()) +assert (model.dof(aSketchFeature) == 3) #========================================================================= # Move one of boundary points of a line #========================================================================= @@ -61,6 +65,7 @@ aLineStartPoint.setValue(aLineStartPoint.x() + deltaX, aLineStartPoint.y() + deltaY) aSession.finishOperation() assert(aLineStartPoint.x() == aLineEndPoint.x()) +assert (model.dof(aSketchFeature) == 3) #========================================================================= # Move other boundary point of a line #========================================================================= @@ -71,9 +76,9 @@ aLineEndPoint.setValue(aLineEndPoint.x() + deltaX, aLineEndPoint.y() + deltaY) aSession.finishOperation() assert(aLineStartPoint.x() == aLineEndPoint.x()) +assert (model.dof(aSketchFeature) == 3) #========================================================================= # End of test #========================================================================= -from salome.shaper import model assert(model.checkPythonDump())