From cb3b1befb8fa7b3067d9263f94391108429d691a Mon Sep 17 00:00:00 2001 From: mpv Date: Fri, 12 Aug 2016 19:44:30 +0300 Subject: [PATCH] Added python dump checking for every unit test where it is useful. --- src/BuildPlugin/Test/TestEdge.py | 3 +++ src/BuildPlugin/Test/TestFace.py | 3 +++ src/BuildPlugin/Test/TestShell.py | 3 +++ src/BuildPlugin/Test/TestSubShapes.py | 3 +++ src/BuildPlugin/Test/TestVertex.py | 3 +++ src/BuildPlugin/Test/TestWire.py | 3 +++ src/ConstructionAPI/Test/TestAxis.py | 2 ++ src/ConstructionAPI/Test/TestPoint.py | 2 ++ src/ConstructionPlugin/Test/TestAxisCreation.py | 3 +++ src/ConstructionPlugin/Test/TestPlane.py | 3 +++ src/ConstructionPlugin/Test/TestPoint.py | 2 +- src/ConstructionPlugin/Test/TestPointName.py | 3 +++ src/ConstructionPlugin/Test/UnitTestAxis.py | 3 +++ src/ExchangeAPI/Test/TestExchange.py | 2 ++ src/ExchangePlugin/Test/TestExport.py | 2 ++ src/ExchangePlugin/Test/TestImport.py | 3 +++ src/FeaturesPlugin/Test/TestBoolean.py | 3 +++ src/FeaturesPlugin/Test/TestBooleanCompSolids.py | 3 +++ src/FeaturesPlugin/Test/TestBooleanFill.py | 2 ++ src/FeaturesPlugin/Test/TestBooleanSmash.py | 3 +++ .../Test/TestCompositeFeaturesOnCompSolids.py | 3 +++ src/FeaturesPlugin/Test/TestExtrusion.py | 3 +++ src/FeaturesPlugin/Test/TestExtrusionCut.py | 3 +++ src/FeaturesPlugin/Test/TestExtrusionFuse.py | 3 +++ src/FeaturesPlugin/Test/TestGroup.py | 3 +++ src/FeaturesPlugin/Test/TestIntersection.py | 3 +++ src/FeaturesPlugin/Test/TestMultiBoolean.py | 3 +++ src/FeaturesPlugin/Test/TestPartition.py | 3 +++ src/FeaturesPlugin/Test/TestPipe.py | 3 +++ src/FeaturesPlugin/Test/TestPlacement.py | 3 +++ src/FeaturesPlugin/Test/TestRecover.py | 2 ++ src/FeaturesPlugin/Test/TestRemoveSubShapes.py | 3 +++ src/FeaturesPlugin/Test/TestRevolution.py | 3 +++ src/FeaturesPlugin/Test/TestRevolutionCut.py | 3 +++ src/FeaturesPlugin/Test/TestRevolutionFuse.py | 3 +++ src/FeaturesPlugin/Test/TestRotation.py | 2 ++ src/FeaturesPlugin/Test/TestSerialBoolean.py | 3 +++ src/FeaturesPlugin/Test/TestTranslation.py | 2 ++ src/FeaturesPlugin/Test/TestUnion.py | 3 +++ src/ModelAPI/Test/Test1064.py | 3 +++ src/ModelAPI/Test/Test1512.py | 3 +++ src/ModelAPI/Test/TestDocument.py | 3 +++ src/ModelAPI/Test/TestDoubleArray.py | 3 +++ src/ModelAPI/Test/TestIntArray.py | 3 +++ src/ModelAPI/Test/TestResults.py | 2 ++ src/ModelAPI/Test/TestUndoRedo.py | 3 +++ src/ModelGeomAlgo/Test/TestPoint2D.py | 3 +++ src/ModelHighAPI/ModelHighAPI_FeatureStore.cpp | 10 ++++++++-- src/ModelHighAPI/ModelHighAPI_Tools.cpp | 2 +- src/ParametersPlugin/Test/TestParameterChangeValue.py | 2 ++ src/ParametersPlugin/Test/TestParameterCreation.py | 3 +++ src/ParametersPlugin/Test/TestParameterRename.py | 2 ++ src/PythonAPI/Test/TestFeatures.py | 1 + src/PythonAPI/Test/TestFeaturesExtrusion.py | 1 + src/PythonAPI/Test/TestFeaturesRevolution.py | 1 + src/PythonAPI/Test/TestModel.py | 1 + src/PythonAPI/Test/TestSketcher.py | 1 + src/PythonAPI/examples/MakeBrick1.py | 2 ++ src/PythonAPI/examples/MakeBrick2.py | 2 ++ src/PythonAPI/examples/MakeBrick3.py | 1 + src/PythonAPI/examples/Platine.py | 2 ++ src/SketchPlugin/Test/TestConstraintAngle.py | 3 +++ src/SketchPlugin/Test/TestConstraintCoincidence.py | 3 +++ src/SketchPlugin/Test/TestConstraintCollinear.py | 3 +++ src/SketchPlugin/Test/TestConstraintDistance.py | 3 +++ src/SketchPlugin/Test/TestConstraintEqual.py | 3 +++ src/SketchPlugin/Test/TestConstraintHorizontal.py | 3 +++ src/SketchPlugin/Test/TestConstraintLength.py | 3 +++ src/SketchPlugin/Test/TestConstraintMiddlePoint.py | 3 +++ src/SketchPlugin/Test/TestConstraintMirror.py | 3 +++ src/SketchPlugin/Test/TestConstraintParallel.py | 3 +++ src/SketchPlugin/Test/TestConstraintPerpendicular.py | 3 +++ src/SketchPlugin/Test/TestConstraintRadius.py | 3 +++ src/SketchPlugin/Test/TestConstraintRigid.py | 3 +++ src/SketchPlugin/Test/TestConstraintTangent.py | 3 +++ src/SketchPlugin/Test/TestConstraintVertical.py | 3 +++ src/SketchPlugin/Test/TestFillet.py | 3 +++ src/SketchPlugin/Test/TestHighload.py | 3 +++ src/SketchPlugin/Test/TestMultiRotation.py | 3 +++ src/SketchPlugin/Test/TestMultiTranslation.py | 3 +++ src/SketchPlugin/Test/TestProjection.py | 3 +++ src/SketchPlugin/Test/TestRectangle.py | 3 +++ src/SketchPlugin/Test/TestSketchArcCircle.py | 3 +++ src/SketchPlugin/Test/TestSketchPointLine.py | 3 +++ src/SketchPlugin/Test/TestSnowflake.py | 3 +++ 85 files changed, 230 insertions(+), 4 deletions(-) diff --git a/src/BuildPlugin/Test/TestEdge.py b/src/BuildPlugin/Test/TestEdge.py index 5c5ebb590..648aa57d8 100644 --- a/src/BuildPlugin/Test/TestEdge.py +++ b/src/BuildPlugin/Test/TestEdge.py @@ -54,3 +54,6 @@ aSession.finishOperation() # Test results assert (len(anEdgeFeature.results()) == aNumOfLines) + +import model +assert(model.checkPythonDump()) diff --git a/src/BuildPlugin/Test/TestFace.py b/src/BuildPlugin/Test/TestFace.py index bd85a3a61..9f4b9e828 100644 --- a/src/BuildPlugin/Test/TestFace.py +++ b/src/BuildPlugin/Test/TestFace.py @@ -62,3 +62,6 @@ aSession.finishOperation() # Test results assert (len(aFaceFeature.results()) > 0) + +import model +assert(model.checkPythonDump()) diff --git a/src/BuildPlugin/Test/TestShell.py b/src/BuildPlugin/Test/TestShell.py index cd06246f1..2406a93b5 100644 --- a/src/BuildPlugin/Test/TestShell.py +++ b/src/BuildPlugin/Test/TestShell.py @@ -77,3 +77,6 @@ aSession.finishOperation() # Test results assert (len(aShellFeature.results()) > 0) + +import model +assert(model.checkPythonDump()) diff --git a/src/BuildPlugin/Test/TestSubShapes.py b/src/BuildPlugin/Test/TestSubShapes.py index 59668662c..e943f66b3 100644 --- a/src/BuildPlugin/Test/TestSubShapes.py +++ b/src/BuildPlugin/Test/TestSubShapes.py @@ -126,3 +126,6 @@ aSession.finishOperation() # Test results assert (len(aSubShapesFeature.results()) > 0) + +import model +assert(model.checkPythonDump()) diff --git a/src/BuildPlugin/Test/TestVertex.py b/src/BuildPlugin/Test/TestVertex.py index cc2da7929..d292e6aaf 100644 --- a/src/BuildPlugin/Test/TestVertex.py +++ b/src/BuildPlugin/Test/TestVertex.py @@ -55,3 +55,6 @@ aSession.finishOperation() # Test results assert (len(aVertexFeature.results()) == aNumOfPoints) + +import model +assert(model.checkPythonDump()) diff --git a/src/BuildPlugin/Test/TestWire.py b/src/BuildPlugin/Test/TestWire.py index 9b50b70ee..545c5ffa6 100644 --- a/src/BuildPlugin/Test/TestWire.py +++ b/src/BuildPlugin/Test/TestWire.py @@ -62,3 +62,6 @@ aSession.finishOperation() # Test results assert (len(aWireFeature.results()) > 0) + +import model +assert(model.checkPythonDump()) diff --git a/src/ConstructionAPI/Test/TestAxis.py b/src/ConstructionAPI/Test/TestAxis.py index 626ff62b7..ddce01998 100644 --- a/src/ConstructionAPI/Test/TestAxis.py +++ b/src/ConstructionAPI/Test/TestAxis.py @@ -2,6 +2,7 @@ import unittest import ModelAPI import ConstructionAPI +import model class AxisTestCase(unittest.TestCase): @@ -14,6 +15,7 @@ class AxisTestCase(unittest.TestCase): self.session.finishOperation() def tearDown(self): + assert(model.checkPythonDump()) self.session.closeAll() def test_ConstructorWithDimensions(self): diff --git a/src/ConstructionAPI/Test/TestPoint.py b/src/ConstructionAPI/Test/TestPoint.py index a1bc2eca7..e2da3460a 100644 --- a/src/ConstructionAPI/Test/TestPoint.py +++ b/src/ConstructionAPI/Test/TestPoint.py @@ -2,6 +2,7 @@ import unittest import ModelAPI import ConstructionAPI +import model class PointTestCase(unittest.TestCase): @@ -14,6 +15,7 @@ class PointTestCase(unittest.TestCase): self.session.finishOperation() def tearDown(self): + assert(model.checkPythonDump()) self.session.closeAll() def test_ConstructorWithValues(self): diff --git a/src/ConstructionPlugin/Test/TestAxisCreation.py b/src/ConstructionPlugin/Test/TestAxisCreation.py index 86ce8bc37..77be60ef1 100644 --- a/src/ConstructionPlugin/Test/TestAxisCreation.py +++ b/src/ConstructionPlugin/Test/TestAxisCreation.py @@ -188,3 +188,6 @@ aSession.startOperation() anAxis = model.addAxis(aPart, aPlane1.result()[0], 50, False, aPlane2.result()[0], 100, True) aSession.finishOperation() assert (len(anAxis.result()) > 0) + +#import model +#assert(model.checkPythonDump()) diff --git a/src/ConstructionPlugin/Test/TestPlane.py b/src/ConstructionPlugin/Test/TestPlane.py index 0661b4dd3..3a3b7c862 100644 --- a/src/ConstructionPlugin/Test/TestPlane.py +++ b/src/ConstructionPlugin/Test/TestPlane.py @@ -82,3 +82,6 @@ aSession.startOperation() aPlane = model.addPlane(aDocument, aCoincidentPlane.result()[0], aPlane.result()[0]) aSession.finishOperation() assert (len(aPlane.result()) > 0) + +import model +assert(model.checkPythonDump()) diff --git a/src/ConstructionPlugin/Test/TestPoint.py b/src/ConstructionPlugin/Test/TestPoint.py index 4afd7f2b9..d91d74634 100644 --- a/src/ConstructionPlugin/Test/TestPoint.py +++ b/src/ConstructionPlugin/Test/TestPoint.py @@ -61,4 +61,4 @@ assert (len(aPoint.result()) > 0) # aSession.finishOperation() # assert (len(aPoint.result()) > 0) -assert(model.checkPythonDump()) \ No newline at end of file +assert(model.checkPythonDump()) diff --git a/src/ConstructionPlugin/Test/TestPointName.py b/src/ConstructionPlugin/Test/TestPointName.py index fcf606b05..9d17c2294 100644 --- a/src/ConstructionPlugin/Test/TestPointName.py +++ b/src/ConstructionPlugin/Test/TestPointName.py @@ -20,3 +20,6 @@ aFeature1 = aDoc.object("Construction", 7) aFeature1Name = aFeature1.data().name() assert (aFeatureName == aFeature1Name) + +import model +assert(model.checkPythonDump()) diff --git a/src/ConstructionPlugin/Test/UnitTestAxis.py b/src/ConstructionPlugin/Test/UnitTestAxis.py index 845dcef37..9dbb8c8fc 100644 --- a/src/ConstructionPlugin/Test/UnitTestAxis.py +++ b/src/ConstructionPlugin/Test/UnitTestAxis.py @@ -74,3 +74,6 @@ aSession.finishOperation() #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/ExchangeAPI/Test/TestExchange.py b/src/ExchangeAPI/Test/TestExchange.py index 681688fa1..d7cc004be 100644 --- a/src/ExchangeAPI/Test/TestExchange.py +++ b/src/ExchangeAPI/Test/TestExchange.py @@ -2,6 +2,7 @@ import unittest import ModelAPI import ExchangeAPI +import model class ExchangeTestCase(unittest.TestCase): @@ -10,6 +11,7 @@ class ExchangeTestCase(unittest.TestCase): self.doc = self.session.moduleDocument() def tearDown(self): + assert(model.checkPythonDump()) self.session.closeAll() def test_addImport(self): diff --git a/src/ExchangePlugin/Test/TestExport.py b/src/ExchangePlugin/Test/TestExport.py index a8113e799..d167177bd 100644 --- a/src/ExchangePlugin/Test/TestExport.py +++ b/src/ExchangePlugin/Test/TestExport.py @@ -145,3 +145,5 @@ if __name__ == '__main__': #========================================================================= # End of test #========================================================================= + +assert(model.checkPythonDump()) diff --git a/src/ExchangePlugin/Test/TestImport.py b/src/ExchangePlugin/Test/TestImport.py index 5a07ad66a..0dbffdea6 100644 --- a/src/ExchangePlugin/Test/TestImport.py +++ b/src/ExchangePlugin/Test/TestImport.py @@ -108,3 +108,6 @@ if __name__ == '__main__': #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestBoolean.py b/src/FeaturesPlugin/Test/TestBoolean.py index c83eb2f2b..c1b686df9 100644 --- a/src/FeaturesPlugin/Test/TestBoolean.py +++ b/src/FeaturesPlugin/Test/TestBoolean.py @@ -118,3 +118,6 @@ assert (aBooleanResult is not None) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestBooleanCompSolids.py b/src/FeaturesPlugin/Test/TestBooleanCompSolids.py index ed2a60514..8d997e60e 100644 --- a/src/FeaturesPlugin/Test/TestBooleanCompSolids.py +++ b/src/FeaturesPlugin/Test/TestBooleanCompSolids.py @@ -128,3 +128,6 @@ assert (aBooleanResult is not None) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestBooleanFill.py b/src/FeaturesPlugin/Test/TestBooleanFill.py index 26caead92..524286a35 100644 --- a/src/FeaturesPlugin/Test/TestBooleanFill.py +++ b/src/FeaturesPlugin/Test/TestBooleanFill.py @@ -43,3 +43,5 @@ aSession.startOperation() aBoolean = model.addFill(aDocument, [anExtrusion.result()[0]], [anExtrusion.result()[1]]) assert (len(aBoolean.result()) > 0) aSession.finishOperation() + +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestBooleanSmash.py b/src/FeaturesPlugin/Test/TestBooleanSmash.py index 8591f52d0..2190346cf 100644 --- a/src/FeaturesPlugin/Test/TestBooleanSmash.py +++ b/src/FeaturesPlugin/Test/TestBooleanSmash.py @@ -102,3 +102,6 @@ assert (aBooleanResult is not None) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestCompositeFeaturesOnCompSolids.py b/src/FeaturesPlugin/Test/TestCompositeFeaturesOnCompSolids.py index 1f9f97c49..0e556e5fa 100644 --- a/src/FeaturesPlugin/Test/TestCompositeFeaturesOnCompSolids.py +++ b/src/FeaturesPlugin/Test/TestCompositeFeaturesOnCompSolids.py @@ -224,3 +224,6 @@ assert (aFactory.validate(anRevolutionFuseFt)) assert (len(anRevolutionFuseFt.results()) > 0) aCurrentResult = modelAPI_ResultBody(anRevolutionFuseFt.firstResult()) assert (aCurrentResult is not None) + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestExtrusion.py b/src/FeaturesPlugin/Test/TestExtrusion.py index 9a5c6d784..ea0865310 100644 --- a/src/FeaturesPlugin/Test/TestExtrusion.py +++ b/src/FeaturesPlugin/Test/TestExtrusion.py @@ -245,3 +245,6 @@ assert (anExtrusionResult is not None) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestExtrusionCut.py b/src/FeaturesPlugin/Test/TestExtrusionCut.py index e880babc7..72a536f98 100644 --- a/src/FeaturesPlugin/Test/TestExtrusionCut.py +++ b/src/FeaturesPlugin/Test/TestExtrusionCut.py @@ -117,3 +117,6 @@ assert (aFactory.validate(anExtrusionCutFt)) assert (len(anExtrusionCutFt.results()) > 0) aCurrentResult = modelAPI_ResultBody(anExtrusionCutFt.firstResult()) assert (aCurrentResult is not None) + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestExtrusionFuse.py b/src/FeaturesPlugin/Test/TestExtrusionFuse.py index 5832c3baa..e57883994 100644 --- a/src/FeaturesPlugin/Test/TestExtrusionFuse.py +++ b/src/FeaturesPlugin/Test/TestExtrusionFuse.py @@ -117,3 +117,6 @@ assert (aFactory.validate(anExtrusionFuseFt)) assert (len(anExtrusionFuseFt.results()) > 0) aCurrentResult = modelAPI_ResultBody(anExtrusionFuseFt.firstResult()) assert (aCurrentResult is not None) + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestGroup.py b/src/FeaturesPlugin/Test/TestGroup.py index a2ca95ef1..139d41208 100644 --- a/src/FeaturesPlugin/Test/TestGroup.py +++ b/src/FeaturesPlugin/Test/TestGroup.py @@ -242,3 +242,6 @@ assert(aGroupResult.shape()) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestIntersection.py b/src/FeaturesPlugin/Test/TestIntersection.py index 04490b0f7..2915cff86 100644 --- a/src/FeaturesPlugin/Test/TestIntersection.py +++ b/src/FeaturesPlugin/Test/TestIntersection.py @@ -146,3 +146,6 @@ assert (aFactory.validate(anIntersectionFt)) assert (len(anIntersectionFt.results()) > 0) anItersectionResult = modelAPI_ResultBody(anIntersectionFt.firstResult()) assert (anItersectionResult is not None) + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestMultiBoolean.py b/src/FeaturesPlugin/Test/TestMultiBoolean.py index 65ca076f1..b6a6e742c 100644 --- a/src/FeaturesPlugin/Test/TestMultiBoolean.py +++ b/src/FeaturesPlugin/Test/TestMultiBoolean.py @@ -192,3 +192,6 @@ aSession.finishOperation() #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestPartition.py b/src/FeaturesPlugin/Test/TestPartition.py index db00eaeef..dbc14ed94 100644 --- a/src/FeaturesPlugin/Test/TestPartition.py +++ b/src/FeaturesPlugin/Test/TestPartition.py @@ -129,3 +129,6 @@ assert (aFactory.validate(aPartitionFt)) assert (len(aPartitionFt.results()) > 0) aPartitionResult = modelAPI_ResultBody(aPartitionFt.firstResult()) assert (aPartitionResult is not None) + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestPipe.py b/src/FeaturesPlugin/Test/TestPipe.py index 5623aa594..5cd9a2b9a 100644 --- a/src/FeaturesPlugin/Test/TestPipe.py +++ b/src/FeaturesPlugin/Test/TestPipe.py @@ -163,3 +163,6 @@ aSession.finishOperation() # Test results assert (len(aPipeFeature.results()) > 0) + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestPlacement.py b/src/FeaturesPlugin/Test/TestPlacement.py index 58e328fa9..24619f217 100644 --- a/src/FeaturesPlugin/Test/TestPlacement.py +++ b/src/FeaturesPlugin/Test/TestPlacement.py @@ -217,3 +217,6 @@ aSession.finishOperation() assert (len(aPlacementFt.results()) > 0) aPlacementResult = modelAPI_ResultBody(aPlacementFt.firstResult()) assert (aPlacementResult is not None) + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestRecover.py b/src/FeaturesPlugin/Test/TestRecover.py index 28a47fc83..867ecc32f 100644 --- a/src/FeaturesPlugin/Test/TestRecover.py +++ b/src/FeaturesPlugin/Test/TestRecover.py @@ -64,3 +64,5 @@ recover.setIsPersistent(False) model.end() # only two booleans assert(mypart.size("Bodies") == 2) + +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestRemoveSubShapes.py b/src/FeaturesPlugin/Test/TestRemoveSubShapes.py index 6685760da..713e7e94e 100644 --- a/src/FeaturesPlugin/Test/TestRemoveSubShapes.py +++ b/src/FeaturesPlugin/Test/TestRemoveSubShapes.py @@ -72,3 +72,6 @@ aSession.finishOperation() assert (len(aRemoveSubShapesFeature.results()) > 0) anUnionResult = modelAPI_ResultCompSolid(modelAPI_ResultBody(aRemoveSubShapesFeature.firstResult())) assert (anUnionResult.numberOfSubs() == 2) + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestRevolution.py b/src/FeaturesPlugin/Test/TestRevolution.py index 3f46da758..cfac07013 100644 --- a/src/FeaturesPlugin/Test/TestRevolution.py +++ b/src/FeaturesPlugin/Test/TestRevolution.py @@ -206,3 +206,6 @@ aSession.finishOperation() assert (len(aRevolFt.results()) > 0) aRevolResult = modelAPI_ResultBody(aRevolFt.firstResult()) assert (aRevolResult is not None) + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestRevolutionCut.py b/src/FeaturesPlugin/Test/TestRevolutionCut.py index ca8f2b57b..6ec4eb3b5 100644 --- a/src/FeaturesPlugin/Test/TestRevolutionCut.py +++ b/src/FeaturesPlugin/Test/TestRevolutionCut.py @@ -144,3 +144,6 @@ assert (aFactory.validate(anRevolutionCutFt)) assert (len(anRevolutionCutFt.results()) > 0) aCurrentResult = modelAPI_ResultBody(anRevolutionCutFt.firstResult()) assert (aCurrentResult is not None) + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestRevolutionFuse.py b/src/FeaturesPlugin/Test/TestRevolutionFuse.py index 369c413a0..807a4d443 100644 --- a/src/FeaturesPlugin/Test/TestRevolutionFuse.py +++ b/src/FeaturesPlugin/Test/TestRevolutionFuse.py @@ -172,3 +172,6 @@ assert (aFactory.validate(anRevolutionFuseFt)) assert (len(anRevolutionFuseFt.results()) > 0) aCurrentResult = modelAPI_ResultBody(anRevolutionFuseFt.firstResult()) assert (aCurrentResult is not None) + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestRotation.py b/src/FeaturesPlugin/Test/TestRotation.py index e86b7b8e9..9cd1479c5 100644 --- a/src/FeaturesPlugin/Test/TestRotation.py +++ b/src/FeaturesPlugin/Test/TestRotation.py @@ -132,3 +132,5 @@ assert (len(aRotateFt.results()) > 0) aMoveResult = modelAPI_ResultBody(aRotateFt.firstResult()) assert (aMoveResult is not None) +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestSerialBoolean.py b/src/FeaturesPlugin/Test/TestSerialBoolean.py index ce9fa6734..9b248edcc 100644 --- a/src/FeaturesPlugin/Test/TestSerialBoolean.py +++ b/src/FeaturesPlugin/Test/TestSerialBoolean.py @@ -192,3 +192,6 @@ aSession.finishOperation() #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestTranslation.py b/src/FeaturesPlugin/Test/TestTranslation.py index dd90e09ea..820b72c62 100644 --- a/src/FeaturesPlugin/Test/TestTranslation.py +++ b/src/FeaturesPlugin/Test/TestTranslation.py @@ -132,3 +132,5 @@ assert (len(aMoveFt.results()) > 0) aMoveResult = modelAPI_ResultBody(aMoveFt.firstResult()) assert (aMoveResult is not None) +import model +assert(model.checkPythonDump()) diff --git a/src/FeaturesPlugin/Test/TestUnion.py b/src/FeaturesPlugin/Test/TestUnion.py index 562645c42..eb4be902a 100644 --- a/src/FeaturesPlugin/Test/TestUnion.py +++ b/src/FeaturesPlugin/Test/TestUnion.py @@ -73,3 +73,6 @@ aSession.finishOperation() assert (len(aUnionFeature.results()) > 0) anUnionResult = modelAPI_ResultCompSolid(modelAPI_ResultBody(aUnionFeature.firstResult())) assert (anUnionResult.numberOfSubs() == 0) + +import model +assert(model.checkPythonDump()) diff --git a/src/ModelAPI/Test/Test1064.py b/src/ModelAPI/Test/Test1064.py index efd57540f..4f433271e 100644 --- a/src/ModelAPI/Test/Test1064.py +++ b/src/ModelAPI/Test/Test1064.py @@ -105,3 +105,6 @@ assert(aPln.direction().z() == 0.) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/ModelAPI/Test/Test1512.py b/src/ModelAPI/Test/Test1512.py index 25f843acf..491061c9b 100755 --- a/src/ModelAPI/Test/Test1512.py +++ b/src/ModelAPI/Test/Test1512.py @@ -149,3 +149,6 @@ assert(aFuse.firstResult().shape().isConnectedTopology() == False) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/ModelAPI/Test/TestDocument.py b/src/ModelAPI/Test/TestDocument.py index 14bf232bb..7ff8a9450 100644 --- a/src/ModelAPI/Test/TestDocument.py +++ b/src/ModelAPI/Test/TestDocument.py @@ -88,3 +88,6 @@ aDoc2.addFeature("Remove") aSession.finishOperation() assert(aSession.moduleDocument().size("Parts") == 0) assert(aSession.activeDocument()) + +import model +assert(model.checkPythonDump()) diff --git a/src/ModelAPI/Test/TestDoubleArray.py b/src/ModelAPI/Test/TestDoubleArray.py index 88a1099c2..f546ea4a9 100644 --- a/src/ModelAPI/Test/TestDoubleArray.py +++ b/src/ModelAPI/Test/TestDoubleArray.py @@ -28,3 +28,6 @@ assert(math.fabs(aFeatureData.realArray("double_array").value(1) - 1.5) < 10 ** #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/ModelAPI/Test/TestIntArray.py b/src/ModelAPI/Test/TestIntArray.py index 6b540f850..66a1a0a21 100755 --- a/src/ModelAPI/Test/TestIntArray.py +++ b/src/ModelAPI/Test/TestIntArray.py @@ -29,3 +29,6 @@ assert(aFeatureData.intArray("IntArray_1").size() == 5) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/ModelAPI/Test/TestResults.py b/src/ModelAPI/Test/TestResults.py index 7ba9cb5ea..b74b29e7e 100755 --- a/src/ModelAPI/Test/TestResults.py +++ b/src/ModelAPI/Test/TestResults.py @@ -34,3 +34,5 @@ assert(aColors.value(2) == 250) aSession.finishOperation() +import model +assert(model.checkPythonDump()) diff --git a/src/ModelAPI/Test/TestUndoRedo.py b/src/ModelAPI/Test/TestUndoRedo.py index 2f86fbefc..3981f30d4 100644 --- a/src/ModelAPI/Test/TestUndoRedo.py +++ b/src/ModelAPI/Test/TestUndoRedo.py @@ -32,3 +32,6 @@ aSession.redo() assert(aDoc.size("Construction") == 8) assert(aSession.canUndo()) assert(not aSession.canRedo()) + +import model +assert(model.checkPythonDump()) diff --git a/src/ModelGeomAlgo/Test/TestPoint2D.py b/src/ModelGeomAlgo/Test/TestPoint2D.py index c0344eab2..b43279ad5 100755 --- a/src/ModelGeomAlgo/Test/TestPoint2D.py +++ b/src/ModelGeomAlgo/Test/TestPoint2D.py @@ -15,3 +15,6 @@ from ModelGeomAlgo import * __updated__ = "2016-07-20" aSession = ModelAPI_Session.get() + +import model +assert(model.checkPythonDump()) diff --git a/src/ModelHighAPI/ModelHighAPI_FeatureStore.cpp b/src/ModelHighAPI/ModelHighAPI_FeatureStore.cpp index ed67336a7..c9ff7f1f4 100644 --- a/src/ModelHighAPI/ModelHighAPI_FeatureStore.cpp +++ b/src/ModelHighAPI/ModelHighAPI_FeatureStore.cpp @@ -22,6 +22,7 @@ #include #include #include +#include #include #include @@ -95,8 +96,8 @@ std::string ModelHighAPI_FeatureStore::compareData(std::shared_ptrfirst + "'"; } if (theAttrs[aThisIter->first] != aThisIter->second) { - return "attribute '" + aThisIter->first + "' is different '" + - theAttrs[aThisIter->first] + "' != '" + aThisIter->second; + return "attribute '" + aThisIter->first + "' is different (original != current) '" + + theAttrs[aThisIter->first] + "' != '" + aThisIter->second + "'"; } } // iterate back to find lack attribute in the current model @@ -110,6 +111,11 @@ std::string ModelHighAPI_FeatureStore::compareData(std::shared_ptrvalidators(); + FeaturePtr aFeatOwner = std::dynamic_pointer_cast(theAttr->owner()); + if (aFeatOwner.get() && !aFactory->isCase(aFeatOwner, theAttr->id())) { + return "__notcase__"; + } if (!theAttr->isInitialized()) { return "__notinitialized__"; } diff --git a/src/ModelHighAPI/ModelHighAPI_Tools.cpp b/src/ModelHighAPI/ModelHighAPI_Tools.cpp index c19f47409..7931f0dca 100644 --- a/src/ModelHighAPI/ModelHighAPI_Tools.cpp +++ b/src/ModelHighAPI/ModelHighAPI_Tools.cpp @@ -309,7 +309,7 @@ std::string storeFeatures(const std::string& theDocName, DocumentPtr theDoc, } } return "For document '" + theDocName + - "' the number of features becomes smaller, there is no feature '" + aLostName + "'"; + "' the number of features is decreased, there is no feature '" + aLostName + "'"; } } return ""; // ok diff --git a/src/ParametersPlugin/Test/TestParameterChangeValue.py b/src/ParametersPlugin/Test/TestParameterChangeValue.py index 4e810d765..46b076db2 100644 --- a/src/ParametersPlugin/Test/TestParameterChangeValue.py +++ b/src/ParametersPlugin/Test/TestParameterChangeValue.py @@ -23,6 +23,7 @@ from GeomDataAPI import * from ModelAPI import * import math import unittest +import model __updated__ = "2015-04-27" @@ -45,6 +46,7 @@ class TestParameterRename(unittest.TestCase): self.createFeature() def tearDown(self): + assert(model.checkPythonDump()) self.aSession.closeAll() def createParameters(self): diff --git a/src/ParametersPlugin/Test/TestParameterCreation.py b/src/ParametersPlugin/Test/TestParameterCreation.py index d775d7301..a791a54e9 100644 --- a/src/ParametersPlugin/Test/TestParameterCreation.py +++ b/src/ParametersPlugin/Test/TestParameterCreation.py @@ -158,3 +158,6 @@ assert(aLengthAttr.value() == 250.) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/ParametersPlugin/Test/TestParameterRename.py b/src/ParametersPlugin/Test/TestParameterRename.py index 552142630..0605fac1a 100644 --- a/src/ParametersPlugin/Test/TestParameterRename.py +++ b/src/ParametersPlugin/Test/TestParameterRename.py @@ -23,6 +23,7 @@ from GeomDataAPI import * from ModelAPI import * import math import unittest +import model __updated__ = "2015-04-27" @@ -47,6 +48,7 @@ class TestParameterRename(unittest.TestCase): self.createFeature() def tearDown(self): + assert(model.checkPythonDump()) self.aSession.closeAll() def createParameters(self): diff --git a/src/PythonAPI/Test/TestFeatures.py b/src/PythonAPI/Test/TestFeatures.py index 35ff9679e..54fe5510f 100644 --- a/src/PythonAPI/Test/TestFeatures.py +++ b/src/PythonAPI/Test/TestFeatures.py @@ -18,6 +18,7 @@ class FeaturesFixture(unittest.TestCase): def tearDown(self): model.end() + assert(model.checkPythonDump()) model.reset() #----------------------------------------------------------------------------- diff --git a/src/PythonAPI/Test/TestFeaturesExtrusion.py b/src/PythonAPI/Test/TestFeaturesExtrusion.py index ce3935cd9..a58c87662 100644 --- a/src/PythonAPI/Test/TestFeaturesExtrusion.py +++ b/src/PythonAPI/Test/TestFeaturesExtrusion.py @@ -18,6 +18,7 @@ class FeaturesAddExtrusionFixture(unittest.TestCase): def tearDown(self): model.end() + assert(model.checkPythonDump()) model.reset() diff --git a/src/PythonAPI/Test/TestFeaturesRevolution.py b/src/PythonAPI/Test/TestFeaturesRevolution.py index 0a09c8048..90d9af9f6 100644 --- a/src/PythonAPI/Test/TestFeaturesRevolution.py +++ b/src/PythonAPI/Test/TestFeaturesRevolution.py @@ -18,6 +18,7 @@ class FeaturesAddRevolutionFixture(unittest.TestCase): def tearDown(self): model.end() + assert(model.checkPythonDump()) model.reset() diff --git a/src/PythonAPI/Test/TestModel.py b/src/PythonAPI/Test/TestModel.py index d76377736..0a204cf0b 100644 --- a/src/PythonAPI/Test/TestModel.py +++ b/src/PythonAPI/Test/TestModel.py @@ -9,6 +9,7 @@ class ModelTestCase(unittest.TestCase): def tearDown(self): model.end() + assert(model.checkPythonDump()) def test_add_sketch(self): plane = model.defaultPlane("XOY") diff --git a/src/PythonAPI/Test/TestSketcher.py b/src/PythonAPI/Test/TestSketcher.py index 826493a48..d41f7ddcf 100644 --- a/src/PythonAPI/Test/TestSketcher.py +++ b/src/PythonAPI/Test/TestSketcher.py @@ -14,4 +14,5 @@ class SketcherTestCase(unittest.TestCase): def tearDown(self): model.end() + assert(model.checkPythonDump()) model.reset() diff --git a/src/PythonAPI/examples/MakeBrick1.py b/src/PythonAPI/examples/MakeBrick1.py index 10eb81b07..74ce79686 100644 --- a/src/PythonAPI/examples/MakeBrick1.py +++ b/src/PythonAPI/examples/MakeBrick1.py @@ -71,3 +71,5 @@ model.begin() mybase.setValue(mylength, 100) mybox.setSize(80) model.end() + +assert(model.checkPythonDump()) diff --git a/src/PythonAPI/examples/MakeBrick2.py b/src/PythonAPI/examples/MakeBrick2.py index 2086b83c0..0d44f9a1a 100644 --- a/src/PythonAPI/examples/MakeBrick2.py +++ b/src/PythonAPI/examples/MakeBrick2.py @@ -67,3 +67,5 @@ model.begin() mybase.setValue(mylength, 100) mybox.setSize(20) model.end() + +assert(model.checkPythonDump()) \ No newline at end of file diff --git a/src/PythonAPI/examples/MakeBrick3.py b/src/PythonAPI/examples/MakeBrick3.py index edfc0b3e5..898e83bfe 100644 --- a/src/PythonAPI/examples/MakeBrick3.py +++ b/src/PythonAPI/examples/MakeBrick3.py @@ -22,3 +22,4 @@ mypart = model.addPart(mypartset).document() extension.addBoxScript( mypart, 10, 20, 30 ) model.end() +assert(model.checkPythonDump()) \ No newline at end of file diff --git a/src/PythonAPI/examples/Platine.py b/src/PythonAPI/examples/Platine.py index c84684334..f0c236b51 100644 --- a/src/PythonAPI/examples/Platine.py +++ b/src/PythonAPI/examples/Platine.py @@ -218,3 +218,5 @@ b4 = body_4() boolean = model.addFuse(part, boolean.result() + b4.result()) model.end() + +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestConstraintAngle.py b/src/SketchPlugin/Test/TestConstraintAngle.py index 3e0cf8e20..593349f77 100644 --- a/src/SketchPlugin/Test/TestConstraintAngle.py +++ b/src/SketchPlugin/Test/TestConstraintAngle.py @@ -145,3 +145,6 @@ assert (angle(aSketchLineA, aSketchLineB) == NEW_ANGLE_DEGREE) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestConstraintCoincidence.py b/src/SketchPlugin/Test/TestConstraintCoincidence.py index e37159af8..a1697920e 100644 --- a/src/SketchPlugin/Test/TestConstraintCoincidence.py +++ b/src/SketchPlugin/Test/TestConstraintCoincidence.py @@ -209,3 +209,6 @@ assert (aCircleCenter.x() == 0. and aCircleCenter.y() == 0.) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestConstraintCollinear.py b/src/SketchPlugin/Test/TestConstraintCollinear.py index dda5b8de1..b5d898273 100644 --- a/src/SketchPlugin/Test/TestConstraintCollinear.py +++ b/src/SketchPlugin/Test/TestConstraintCollinear.py @@ -100,3 +100,6 @@ checkCollinear(aSketchLineA, aSketchLineB) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestConstraintDistance.py b/src/SketchPlugin/Test/TestConstraintDistance.py index 75ea58854..9f64238c7 100644 --- a/src/SketchPlugin/Test/TestConstraintDistance.py +++ b/src/SketchPlugin/Test/TestConstraintDistance.py @@ -179,3 +179,6 @@ assert (math.fabs(distancePointPoint(aLineAStartPoint, aLineAEndPoint) - PT_LINE #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestConstraintEqual.py b/src/SketchPlugin/Test/TestConstraintEqual.py index d4176eebd..492ecb6fe 100644 --- a/src/SketchPlugin/Test/TestConstraintEqual.py +++ b/src/SketchPlugin/Test/TestConstraintEqual.py @@ -208,3 +208,6 @@ assert (math.fabs(aLine2Len - anExtLineLen) < 1.e-10) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestConstraintHorizontal.py b/src/SketchPlugin/Test/TestConstraintHorizontal.py index 7a7a7d3fa..dc0b226d2 100644 --- a/src/SketchPlugin/Test/TestConstraintHorizontal.py +++ b/src/SketchPlugin/Test/TestConstraintHorizontal.py @@ -74,3 +74,6 @@ assert(aLineStartPoint.y() == aLineEndPoint.y()) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestConstraintLength.py b/src/SketchPlugin/Test/TestConstraintLength.py index 88f9292b6..72db4d76f 100644 --- a/src/SketchPlugin/Test/TestConstraintLength.py +++ b/src/SketchPlugin/Test/TestConstraintLength.py @@ -94,3 +94,6 @@ assert (math.fabs(aLineAEndPoint.x() - aLineAStartPoint.x() - 140) < 1.e-10) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestConstraintMiddlePoint.py b/src/SketchPlugin/Test/TestConstraintMiddlePoint.py index 80ef01817..39db68220 100644 --- a/src/SketchPlugin/Test/TestConstraintMiddlePoint.py +++ b/src/SketchPlugin/Test/TestConstraintMiddlePoint.py @@ -140,3 +140,6 @@ assert (anOriginCoord.x() == 0. and anOriginCoord.y() == 0.) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestConstraintMirror.py b/src/SketchPlugin/Test/TestConstraintMirror.py index 1d06c8d6a..30e8570f4 100644 --- a/src/SketchPlugin/Test/TestConstraintMirror.py +++ b/src/SketchPlugin/Test/TestConstraintMirror.py @@ -201,3 +201,6 @@ checkMirror(aRefListB, aRefListC, aMirrorLine) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestConstraintParallel.py b/src/SketchPlugin/Test/TestConstraintParallel.py index 03eba23cc..076b2fc62 100644 --- a/src/SketchPlugin/Test/TestConstraintParallel.py +++ b/src/SketchPlugin/Test/TestConstraintParallel.py @@ -108,3 +108,6 @@ assert (aLineBEndPointPrev != aLineBEndPointNew) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestConstraintPerpendicular.py b/src/SketchPlugin/Test/TestConstraintPerpendicular.py index 837eb2626..42c2c9857 100644 --- a/src/SketchPlugin/Test/TestConstraintPerpendicular.py +++ b/src/SketchPlugin/Test/TestConstraintPerpendicular.py @@ -121,3 +121,6 @@ assert (aLineBEndPointPrev != (aLineBEndPoint.x(), aLineBEndPoint.y())) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestConstraintRadius.py b/src/SketchPlugin/Test/TestConstraintRadius.py index edc37350b..acef6c2f0 100644 --- a/src/SketchPlugin/Test/TestConstraintRadius.py +++ b/src/SketchPlugin/Test/TestConstraintRadius.py @@ -150,3 +150,6 @@ assert (aCircleRadius.value() == 25) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestConstraintRigid.py b/src/SketchPlugin/Test/TestConstraintRigid.py index 2fe43e557..44f741503 100644 --- a/src/SketchPlugin/Test/TestConstraintRigid.py +++ b/src/SketchPlugin/Test/TestConstraintRigid.py @@ -135,3 +135,6 @@ assert ((aLineCStartPoint.x(), aLineCStartPoint.y()) == (aLineBEndPoint.x(), aLi #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestConstraintTangent.py b/src/SketchPlugin/Test/TestConstraintTangent.py index df3cd3115..69991a49a 100644 --- a/src/SketchPlugin/Test/TestConstraintTangent.py +++ b/src/SketchPlugin/Test/TestConstraintTangent.py @@ -305,3 +305,6 @@ assert(math.fabs(distancePointLine(aCircleCenter, aLine) - round(aCircleRadius.v #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestConstraintVertical.py b/src/SketchPlugin/Test/TestConstraintVertical.py index 3a03d1d0e..f70040248 100644 --- a/src/SketchPlugin/Test/TestConstraintVertical.py +++ b/src/SketchPlugin/Test/TestConstraintVertical.py @@ -74,3 +74,6 @@ assert(aLineStartPoint.x() == aLineEndPoint.x()) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestFillet.py b/src/SketchPlugin/Test/TestFillet.py index bb2735398..2ca48e60d 100644 --- a/src/SketchPlugin/Test/TestFillet.py +++ b/src/SketchPlugin/Test/TestFillet.py @@ -276,3 +276,6 @@ checkFillet(aResObjects, FILLET_RADIUS2) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestHighload.py b/src/SketchPlugin/Test/TestHighload.py index f745cdfa5..372bd4dad 100644 --- a/src/SketchPlugin/Test/TestHighload.py +++ b/src/SketchPlugin/Test/TestHighload.py @@ -119,3 +119,6 @@ aSession.finishOperation() #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestMultiRotation.py b/src/SketchPlugin/Test/TestMultiRotation.py index 27b0aae24..2afda3716 100644 --- a/src/SketchPlugin/Test/TestMultiRotation.py +++ b/src/SketchPlugin/Test/TestMultiRotation.py @@ -219,3 +219,6 @@ checkRotation(aRotated, aNbCopies.value(), CENTER_X, CENTER_Y, ANGLE) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestMultiTranslation.py b/src/SketchPlugin/Test/TestMultiTranslation.py index 2c0a2b937..0d3971e27 100644 --- a/src/SketchPlugin/Test/TestMultiTranslation.py +++ b/src/SketchPlugin/Test/TestMultiTranslation.py @@ -210,3 +210,6 @@ checkTranslation(aTranslated, aNbCopies.value(), DELTA_X, DELTA_Y) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestProjection.py b/src/SketchPlugin/Test/TestProjection.py index 909d079be..0b89eca5f 100644 --- a/src/SketchPlugin/Test/TestProjection.py +++ b/src/SketchPlugin/Test/TestProjection.py @@ -137,3 +137,6 @@ assert(math.fabs(aProjLineEnd.y() - aLineEnd.y()) < 1.e-10) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestRectangle.py b/src/SketchPlugin/Test/TestRectangle.py index d4c7061a3..b822c58d3 100644 --- a/src/SketchPlugin/Test/TestRectangle.py +++ b/src/SketchPlugin/Test/TestRectangle.py @@ -88,3 +88,6 @@ assert (aNbLines == 4) #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestSketchArcCircle.py b/src/SketchPlugin/Test/TestSketchArcCircle.py index 8d8c4c820..d853339c4 100644 --- a/src/SketchPlugin/Test/TestSketchArcCircle.py +++ b/src/SketchPlugin/Test/TestSketchArcCircle.py @@ -249,3 +249,6 @@ aSession.finishOperation() #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestSketchPointLine.py b/src/SketchPlugin/Test/TestSketchPointLine.py index b37b0f61d..55414c9c8 100644 --- a/src/SketchPlugin/Test/TestSketchPointLine.py +++ b/src/SketchPlugin/Test/TestSketchPointLine.py @@ -100,3 +100,6 @@ aResultConstruction = modelAPI_ResultConstruction(aResult) aShape = aResultConstruction.shape() assert (aShape is not None) assert (not aShape.isNull()) + +import model +assert(model.checkPythonDump()) diff --git a/src/SketchPlugin/Test/TestSnowflake.py b/src/SketchPlugin/Test/TestSnowflake.py index e324fd2da..3e8b9e004 100644 --- a/src/SketchPlugin/Test/TestSnowflake.py +++ b/src/SketchPlugin/Test/TestSnowflake.py @@ -155,3 +155,6 @@ aSession.finishOperation() #========================================================================= # End of test #========================================================================= + +import model +assert(model.checkPythonDump()) -- 2.30.2