X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FSketchPlugin%2FTest%2FTestTrimCircleAndArc01.py;h=fe8d49877f78865e814c78534013d0ee34b31e55;hb=88ee9b2b81cf93a6324336b57e30cc8a3a487499;hp=1bb501b1e21aba4832bc2f1b8af8c95e65bb0063;hpb=3a1a1bd9b311b0a2945942519554fefaa8ccbc9b;p=modules%2Fshaper.git diff --git a/src/SketchPlugin/Test/TestTrimCircleAndArc01.py b/src/SketchPlugin/Test/TestTrimCircleAndArc01.py index 1bb501b1e..fe8d49877 100644 --- a/src/SketchPlugin/Test/TestTrimCircleAndArc01.py +++ b/src/SketchPlugin/Test/TestTrimCircleAndArc01.py @@ -1,3 +1,22 @@ +# Copyright (C) 2014-2022 CEA/DEN, EDF R&D +# +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 2.1 of the License, or (at your option) any later version. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this library; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +# +# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com +# + from salome.shaper import model from ModelAPI import * @@ -90,23 +109,11 @@ assert(idList_after.count(SketchLineId) == 6) assert(idList_after.count(SketchConstraintCoincidenceId) == 8) -#check arc position intersections of created arc to an additional line -#SketchLine_intersecting_1 = Sketch.addLine(0, 0, 50, 50) -#SketchLine_intersecting_2 = Sketch.addLine(50, 50, 100, 100) - -#Intersection_Points_1 = ModelGeomAlgo_Point2D.getSetOfPntIntersectedShape(SketchArc, FeatureList([SketchLine_intersecting_1.feature()])) -#Intersection_Points_2 = ModelGeomAlgo_Point2D.getSetOfPntIntersectedShape(SketchArc, FeatureList([SketchLine_intersecting_2.feature()])) - -#assert(len(Intersection_Points_1) == 1) -#assert(len(Intersection_Points_2) == 0) - #add point for check SketchPoint = Sketch.addPoint(GeomPoint.x(), GeomPoint.y()) Intersection_Points_3 = ModelGeomAlgo_Point2D.getSetOfPntIntersectedShape(SketchArc, FeatureList([SketchPoint.feature()])) assert(len(Intersection_Points_3) == 0) - - #perform trim: horizontal #second intersection point - horizontal SketchLine_intersecting_h = Sketch.addLine(10, 48, 72, 48) @@ -154,4 +161,4 @@ assert(len(Intersection_Points_5) == 0) model.end() -#assert(model.checkPythonDump()) +assert(model.checkPythonDump())