From: dbv Date: Fri, 19 Aug 2016 12:02:57 +0000 (+0300) Subject: Issue #1648: Dump Python in the High Level Parameterized Geometry API X-Git-Tag: V_2.5.0~137^2~16 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=58d033aaecb02fc9292cf0e936823fe56a0b01c9;p=modules%2Fshaper.git Issue #1648: Dump Python in the High Level Parameterized Geometry API Tests fix --- diff --git a/src/PythonAPI/examples/MakeBrick2.py b/src/PythonAPI/examples/MakeBrick2.py index 0d44f9a1a..9e74bf609 100644 --- a/src/PythonAPI/examples/MakeBrick2.py +++ b/src/PythonAPI/examples/MakeBrick2.py @@ -32,6 +32,9 @@ mybase.setParallel(line[0], line[2]) mybase.setParallel(line[1], line[3]) mybase.setPerpendicular(line[0], line[3]) +mybase.setVertical(line[0]) +mybase.setFixed(line[0].startPoint()) + mywidth = mybase.setLength(line[0], 50) mylength = mybase.setDistance(line[0].startPoint(), line[2], 50) @@ -39,6 +42,7 @@ mylength = mybase.setDistance(line[0].startPoint(), line[2], 50) # Creating the extrusion mybox = model.addExtrusion(mypart, mybase.selectFace(), 50) +model.do() # Creating a cylinder on a face of the box @@ -51,6 +55,7 @@ mystand = model.addSketch(mypart, thisface) circle = mystand.addCircle(0, 25, 5) mystand.setDistance(circle.center(), mystand.addLine(thisxmin), 10) mystand.setDistance(circle.center(), mystand.addLine(thiszmax), 10) +model.do() myboss = model.addExtrusion(mypart, mystand.selectFace(), -5) @@ -65,7 +70,8 @@ model.end() model.begin() mybase.setValue(mylength, 100) -mybox.setSize(20) +model.do() +mybox.setSize(40) model.end() -assert(model.checkPythonDump()) \ No newline at end of file +assert(model.checkPythonDump())