X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FFeaturesPlugin%2FTest%2FTestUnion.py;h=541ad7344a0088c86295effa6699463e94e7246a;hb=d2c5ce1931ca0695869fbf036af275fe282ab913;hp=3ccfd563b76bc26095e94b72cb01d08fc891b041;hpb=101d3e5334f023119aa62efd4ca0ae5a31ad5a50;p=modules%2Fshaper.git diff --git a/src/FeaturesPlugin/Test/TestUnion.py b/src/FeaturesPlugin/Test/TestUnion.py index 3ccfd563b..541ad7344 100644 --- a/src/FeaturesPlugin/Test/TestUnion.py +++ b/src/FeaturesPlugin/Test/TestUnion.py @@ -1,3 +1,23 @@ +## Copyright (C) 2014-2017 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 +## + #========================================================================= # Initialization of the test #========================================================================= @@ -59,7 +79,7 @@ anExtrusionFeature.real("to_offset").setValue(0) #TODO: remove anExtrusionFeature.real("from_offset").setValue(0) #TODO: remove anExtrusionFeature.execute() aSession.finishOperation() -anExtrusionResult = modelAPI_ResultCompSolid(modelAPI_ResultBody(anExtrusionFeature.firstResult())) +anExtrusionResult = modelAPI_ResultBody(anExtrusionFeature.firstResult()) #========================================================================= # Make union on extrusion @@ -71,7 +91,7 @@ aUnionFeature.selectionList("base_objects").append(anExtrusionResult.subResult(1 aUnionFeature.selectionList("base_objects").append(anExtrusionResult.subResult(2), None); aSession.finishOperation() assert (len(aUnionFeature.results()) > 0) -anUnionResult = modelAPI_ResultCompSolid(modelAPI_ResultBody(aUnionFeature.firstResult())) +anUnionResult = modelAPI_ResultBody(aUnionFeature.firstResult()) assert (anUnionResult.numberOfSubs() == 0) from salome.shaper import model