Salome HOME
Copyright update 2022
[modules/shaper.git] / test.API / SHAPER / Transformations / TestRotation.py
index 7fad6c9ba8b35d433e81c04ca3c6cbc91d71e123..e10de54a5add623085eca8e02ffea2cc66150f1b 100644 (file)
@@ -1,22 +1,21 @@
-## 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<mailto:webmaster.salome@opencascade.com>
-##
+# 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
+#
 
 """
 Test case for Rotation feature.
@@ -117,6 +116,18 @@ model.testNbSubShapes(Rotation_4, GeomAPI_Shape.SOLID, [1])
 model.testNbSubShapes(Rotation_4, GeomAPI_Shape.FACE, [6])
 model.testHaveNamingFaces(Rotation_4, model, Part_1_doc)
 
+model.testNbResults(Rotation_5, 1)
+model.testNbSubResults(Rotation_5, [0])
+model.testNbSubShapes(Rotation_5, GeomAPI_Shape.SOLID, [1])
+model.testNbSubShapes(Rotation_5, GeomAPI_Shape.FACE, [6])
+model.testHaveNamingFaces(Rotation_5, model, Part_1_doc)
+
+model.testNbResults(Rotation_6, 1)
+model.testNbSubResults(Rotation_6, [0])
+model.testNbSubShapes(Rotation_6, GeomAPI_Shape.SOLID, [1])
+model.testNbSubShapes(Rotation_6, GeomAPI_Shape.FACE, [6])
+model.testHaveNamingFaces(Rotation_6, model, Part_1_doc)
+
 model.testNbResults(Rotation_9, 1)
 model.testNbSubResults(Rotation_9, [0])
 model.testNbSubShapes(Rotation_9, GeomAPI_Shape.SOLID, [1])
@@ -136,11 +147,13 @@ model.testNbResults(Rotation_19, 1)
 model.testNbSubResults(Rotation_19, [0])
 
 
-model.testNbResults(Rotation_5, 0)
-assert(Rotation_5.feature().error() == 'Rotation builder :: angle greater than 360 degrees.')
+# This test is OK because we accept angles greater than 360
+#model.testNbResults(Rotation_5, 0)
+#assert(Rotation_5.feature().error() == 'Rotation builder :: angle greater than 360 degrees.')
 
-model.testNbResults(Rotation_6, 0)
-assert(Rotation_6.feature().error() == 'Rotation builder :: angle smaller than -360 degrees.')
+# This test is OK because we accept angles smaller than 360
+#model.testNbResults(Rotation_6, 0)
+#assert(Rotation_6.feature().error() == 'Rotation builder :: angle smaller than -360 degrees.')
 
 model.testNbResults(Rotation_7, 0)
 assert(Rotation_7.feature().error() == 'Attribute "axis_object" is not initialized.')
@@ -173,4 +186,4 @@ assert(Rotation_16.feature().error() == 'Attribute "start_point" is not initiali
 #assert(Rotation_8.feature().error() == 'Attribute "main_object" is not initialized.')
 
 #model.testNbResults(Rotation_17, 0)
-#assert(Rotation_17.feature().error() == 'Attribute "main_object" is not initialized.')
\ No newline at end of file
+#assert(Rotation_17.feature().error() == 'Attribute "main_object" is not initialized.')