Salome HOME
Revert renaming of "Symmetry" feature to "Mirror copy" and implement flag "keep origi...
authorazv <azv@opencascade.com>
Thu, 5 Jul 2018 11:12:19 +0000 (14:12 +0300)
committerazv <azv@opencascade.com>
Thu, 5 Jul 2018 11:12:19 +0000 (14:12 +0300)
This partially reverts commit 8ee98fa59d780cecd828a402544e2cecf3a43807.

src/FeaturesAPI/FeaturesAPI_Symmetry.cpp
src/FeaturesAPI/FeaturesAPI_Symmetry.h
src/FeaturesPlugin/FeaturesPlugin_Symmetry.cpp
src/FeaturesPlugin/FeaturesPlugin_Symmetry.h
src/FeaturesPlugin/plugin-Features.xml
src/FeaturesPlugin/symmetry_widget.xml
src/ModelAPI/Test/TestCustomName_Recover.py
src/PythonAPI/model/features/__init__.py
test.API/SHAPER/Transformations/TestSymmetry.py

index 6e8b8b6220b5557d4e7cbd53bd241c750415bfba..74a85471a25288c45ee896f5da2abceba432261e 100644 (file)
@@ -33,11 +33,13 @@ FeaturesAPI_Symmetry::FeaturesAPI_Symmetry(const std::shared_ptr<ModelAPI_Featur
 //==================================================================================================
 FeaturesAPI_Symmetry::FeaturesAPI_Symmetry(const std::shared_ptr<ModelAPI_Feature>& theFeature,
                                            const std::list<ModelHighAPI_Selection>& theMainObjects,
-                                           const ModelHighAPI_Selection& theObject)
+                                           const ModelHighAPI_Selection& theObject,
+                                           bool theKeepOriginal)
 : ModelHighAPI_Interface(theFeature)
 {
   if(initialize()) {
     fillAttribute(theMainObjects, mainObjects());
+    fillAttribute(theKeepOriginal, keepOriginal());
     GeomAPI_Shape::ShapeType aType = getShapeType(theObject);
     if(aType == GeomAPI_Shape::VERTEX) {
       setPoint(theObject);
@@ -98,7 +100,7 @@ void FeaturesAPI_Symmetry::dump(ModelHighAPI_Dumper& theDumper) const
 
   AttributeSelectionListPtr anAttrObjects =
     aBase->selectionList(FeaturesPlugin_Symmetry::OBJECTS_LIST_ID());
-  theDumper << aBase << " = model.addMirror(" << aDocName << ", " << anAttrObjects;
+  theDumper << aBase << " = model.addSymmetry(" << aDocName << ", " << anAttrObjects;
 
   std::string aCreationMethod =
     aBase->string(FeaturesPlugin_Symmetry::CREATION_METHOD())->value();
@@ -117,14 +119,15 @@ void FeaturesAPI_Symmetry::dump(ModelHighAPI_Dumper& theDumper) const
     theDumper << ", " << anAttrPlane;
   }
 
-  theDumper << ")" << std::endl;
+  theDumper << ", " << keepOriginal() << ")" << std::endl;
 }
 
 //==================================================================================================
-SymmetryPtr addMirror(const std::shared_ptr<ModelAPI_Document>& thePart,
-                      const std::list<ModelHighAPI_Selection>& theMainObjects,
-                      const ModelHighAPI_Selection& theObject)
+SymmetryPtr addSymmetry(const std::shared_ptr<ModelAPI_Document>& thePart,
+                        const std::list<ModelHighAPI_Selection>& theMainObjects,
+                        const ModelHighAPI_Selection& theObject,
+                        bool theKeepOriginal)
 {
   std::shared_ptr<ModelAPI_Feature> aFeature = thePart->addFeature(FeaturesAPI_Symmetry::ID());
-  return SymmetryPtr(new FeaturesAPI_Symmetry(aFeature, theMainObjects, theObject));
+  return SymmetryPtr(new FeaturesAPI_Symmetry(aFeature, theMainObjects, theObject, theKeepOriginal));
 }
index 1b4ab9dacdc172394ea5a61c59474484976e3c20..9ce53f69851af1ab3818a0453568010fccac0daa 100644 (file)
@@ -34,7 +34,7 @@ class ModelHighAPI_Selection;
 
 /// \class FeaturesAPI_Symmetry
 /// \ingroup CPPHighAPI
-/// \brief Interface for the Mirror Copy feature.
+/// \brief Interface for Symmetry feature.
 class FeaturesAPI_Symmetry: public ModelHighAPI_Interface
 {
 public:
@@ -46,13 +46,14 @@ public:
   FEATURESAPI_EXPORT
   explicit FeaturesAPI_Symmetry(const std::shared_ptr<ModelAPI_Feature>& theFeature,
                                 const std::list<ModelHighAPI_Selection>& theMainObjects,
-                                const ModelHighAPI_Selection& theObject);
+                                const ModelHighAPI_Selection& theObject,
+                                bool theKeepOriginal = true);
 
   /// Destructor.
   FEATURESAPI_EXPORT
   virtual ~FeaturesAPI_Symmetry();
 
-  INTERFACE_5(FeaturesPlugin_Symmetry::ID(),
+  INTERFACE_6(FeaturesPlugin_Symmetry::ID(),
               creationMethod, FeaturesPlugin_Symmetry::CREATION_METHOD(),
               ModelAPI_AttributeString, /** Creation method */,
               mainObjects, FeaturesPlugin_Symmetry::OBJECTS_LIST_ID(),
@@ -62,7 +63,9 @@ public:
               axisObject, FeaturesPlugin_Symmetry::AXIS_OBJECT_ID(),
               ModelAPI_AttributeSelection, /** Axis object */,
               planeObject, FeaturesPlugin_Symmetry::PLANE_OBJECT_ID(),
-              ModelAPI_AttributeSelection, /** Plane object */)
+              ModelAPI_AttributeSelection, /** Plane object */,
+              keepOriginal, FeaturesPlugin_Symmetry::KEEP_ORIGINAL_RESULT(),
+              ModelAPI_AttributeBoolean, /** Keep original shape */)
 
   /// Set main objects.
   FEATURESAPI_EXPORT
@@ -89,10 +92,11 @@ public:
 typedef std::shared_ptr<FeaturesAPI_Symmetry> SymmetryPtr;
 
 /// \ingroup CPPHighAPI
-/// \brief Create the Mirror Copy feature.
+/// \brief Create Symmetry feature.
 FEATURESAPI_EXPORT
-SymmetryPtr addMirror(const std::shared_ptr<ModelAPI_Document>& thePart,
-                      const std::list<ModelHighAPI_Selection>& theMainObjects,
-                      const ModelHighAPI_Selection& theObject);
+SymmetryPtr addSymmetry(const std::shared_ptr<ModelAPI_Document>& thePart,
+                        const std::list<ModelHighAPI_Selection>& theMainObjects,
+                        const ModelHighAPI_Selection& theObject,
+                        bool theKeepOriginal = true);
 
 #endif // FEATURESAPI_SYMMETRY_H_
index 418913246cdd883fae29ab0f9c868cdcd0f7e8ef..d3d058ed3a9f35e61b8ead2df25535d601968ed6 100644 (file)
@@ -30,6 +30,7 @@
 #include <GeomAPI_Pln.h>
 #include <GeomAPI_Trsf.h>
 
+#include <ModelAPI_AttributeBoolean.h>
 #include <ModelAPI_AttributeSelectionList.h>
 #include <ModelAPI_AttributeString.h>
 #include <ModelAPI_ResultBody.h>
@@ -60,6 +61,9 @@ void FeaturesPlugin_Symmetry::initAttributes()
 
   data()->addAttribute(FeaturesPlugin_Symmetry::PLANE_OBJECT_ID(),
                        ModelAPI_AttributeSelection::typeId());
+
+  data()->addAttribute(FeaturesPlugin_Symmetry::KEEP_ORIGINAL_RESULT(),
+                       ModelAPI_AttributeBoolean::typeId());
 }
 
 //=================================================================================================
@@ -337,10 +341,14 @@ void FeaturesPlugin_Symmetry::buildResult(GeomAlgoAPI_Symmetry& theSymmetryAlgo,
                                           int theResultIndex)
 {
   // Compose source shape and the result of symmetry.
-  ListOfShape aShapes;
-  aShapes.push_back(theBaseShape);
-  aShapes.push_back(theSymmetryAlgo.shape());
-  std::shared_ptr<GeomAPI_Shape> aCompound = GeomAlgoAPI_CompoundBuilder::compound(aShapes);
+  GeomShapePtr aCompound;
+  if (boolean(KEEP_ORIGINAL_RESULT())->value()) {
+    ListOfShape aShapes;
+    aShapes.push_back(theBaseShape);
+    aShapes.push_back(theSymmetryAlgo.shape());
+    aCompound = GeomAlgoAPI_CompoundBuilder::compound(aShapes);
+  } else
+    aCompound = theSymmetryAlgo.shape();
 
   // Store and name the result.
   ResultBodyPtr aResultBody = document()->createBody(data(), theResultIndex);
@@ -354,12 +362,13 @@ void FeaturesPlugin_Symmetry::buildResult(ResultPartPtr theOriginal,
                                           std::shared_ptr<GeomAPI_Trsf> theTrsf,
                                           int& theResultIndex)
 {
-  std::shared_ptr<GeomAPI_Trsf> anIdentity(new GeomAPI_Trsf());
-  ResultPartPtr aCopy = document()->copyPart(theOriginal, data(), theResultIndex);
-  aCopy->setTrsf(theOriginal, anIdentity);
-  setResult(aCopy, theResultIndex);
-
-  ++theResultIndex;
+  if (boolean(KEEP_ORIGINAL_RESULT())->value()) {
+    std::shared_ptr<GeomAPI_Trsf> anIdentity(new GeomAPI_Trsf());
+    ResultPartPtr aCopy = document()->copyPart(theOriginal, data(), theResultIndex);
+    aCopy->setTrsf(theOriginal, anIdentity);
+    setResult(aCopy, theResultIndex);
+    ++theResultIndex;
+  }
 
   ResultPartPtr aResultPart = document()->copyPart(theOriginal, data(), theResultIndex);
   aResultPart->setTrsf(theOriginal, theTrsf);
index edb152dd117499dc8af9c0bf6746c5efb2379327..f0b296b4663b5d386cab49156780b5b3347a12fb 100644 (file)
@@ -39,7 +39,7 @@ class FeaturesPlugin_Symmetry : public ModelAPI_Feature
   /// Symmetry kind.
   inline static const std::string& ID()
   {
-    static const std::string MY_SYMMETRY_ID("MirrorCopy");
+    static const std::string MY_SYMMETRY_ID("Symmetry");
     return MY_SYMMETRY_ID;
   }
 
@@ -99,6 +99,13 @@ class FeaturesPlugin_Symmetry : public ModelAPI_Feature
     return MY_PLANE_OBJECT_ID;
   }
 
+  /// Attribute name of keeping original shape.
+  inline static const std::string& KEEP_ORIGINAL_RESULT()
+  {
+    static const std::string MY_KEEP_ORIGINAL_RESULT_ID("keep_original");
+    return MY_KEEP_ORIGINAL_RESULT_ID;
+  }
+
   /// \return the kind of a feature.
   FEATURESPLUGIN_EXPORT virtual const std::string& getKind()
   {
index 5a4ac2f526988d246b6aabdc8b5d399e16203bfa..edfabe40704aa47434513f49579d383ad6fb9a6c 100644 (file)
@@ -97,7 +97,7 @@ email : webmaster.salome@opencascade.com<mailto:webmaster.salome@opencascade.com
       <feature id="Rotation" title="Rotation" tooltip="Perform rotation of an objects around the axis to specified angle" icon="icons/Features/rotation.png">
         <source path="rotation_widget.xml"/>
       </feature>
-      <feature id="MirrorCopy" title="Mirror copy" tooltip="Perform symmetry with respect to a point, an axis or a plane" icon="icons/Features/symmetry.png">
+      <feature id="Symmetry" title="Symmetry" tooltip="Perform symmetry with respect to a point, an axis or a plane" icon="icons/Features/symmetry.png">
         <source path="symmetry_widget.xml"/>
       </feature>
       <feature id="LinearCopy" title="Linear copy" tooltip="Perform copy and translate" icon="icons/Features/multitranslation.png">
index 82c276ec1de52464c7f22b46686e9e06e7733b67..9923217faaed1415bab958bc097afdd7ceed7a27 100644 (file)
@@ -76,4 +76,5 @@ email : webmaster.salome@opencascade.com<mailto:webmaster.salome@opencascade.com
       </shape_selector>
     </box>
   </toolbox>
+  <boolvalue id="keep_original" label="Keep original result" default="true" tooltip="Do not remove original shape"/>
 </source>
index cae44462df16b2c985e665bc34e7153537801d19..e069c44fb65b3a7eab72b4bfa3c8bd4198ff7341 100644 (file)
@@ -27,7 +27,7 @@ Part_1_doc = Part_1.document()
 Cylinder_1 = model.addCylinder(Part_1_doc, model.selection("VERTEX", "PartSet/Origin"), model.selection("EDGE", "PartSet/OZ"), 5, 10)
 Cylinder_1.result().setName("cylinder")
 Plane_4 = model.addPlane(Part_1_doc, model.selection("FACE", "cylinder/Face_2"), 10, False)
-Symmetry_1 = model.addMirror(Part_1_doc, [model.selection("SOLID", "cylinder")], model.selection("FACE", "Plane_1"))
+Symmetry_1 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "cylinder")], model.selection("FACE", "Plane_1"))
 model.do()
 
 # check the name of the Symmetry
index 266e7ee8855d3fe3d3624570d07cd4b981b80791..b74ad9b4e90c432c0716f1a83f2494953ec5d6f3 100644 (file)
@@ -1,7 +1,7 @@
 """Package for Features plugin for the Parametric Geometry API of the Modeler.
 """
 
-from FeaturesAPI import addPlacement, addRotation, addScale, addMirror, addTranslation
+from FeaturesAPI import addPlacement, addRotation, addScale, addSymmetry, addTranslation
 from FeaturesAPI import addMultiTranslation, addMultiRotation
 from FeaturesAPI import addExtrusion, addExtrusionCut, addExtrusionFuse
 from FeaturesAPI import addRevolution, addRevolutionCut, addRevolutionFuse
index d7e0195fac79fdf93d704544ffdd094f9df200f4..eb7617b25af10144943797fc7a4ebff961834e03 100644 (file)
@@ -47,6 +47,9 @@ Box_14 = model.addBox(Part_1_doc, 10, 10, 10)
 Box_15 = model.addBox(Part_1_doc, 10, 10, 10)
 Box_16 = model.addBox(Part_1_doc, 10, 10, 10)
 Box_17 = model.addBox(Part_1_doc, 10, 10, 10)
+Box_18 = model.addBox(Part_1_doc, 10, 10, 10)
+Box_19 = model.addBox(Part_1_doc, 10, 10, 10)
+Box_20 = model.addBox(Part_1_doc, 10, 10, 10)
 
 # Points
 Point_1 = model.addPoint(Part_1_doc, -10, -10, -10)
@@ -104,26 +107,29 @@ Face_1 = model.addFace(Part_1_doc, [model.selection("WIRE", "Sketch_2/Wire-Sketc
 
 
 # Symmetries
-Symmetry_1 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_1_1")], model.selection("VERTEX", "PartSet/Origin"))
-Symmetry_2 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_2_1")], model.selection("VERTEX", "Point_1"))
-Symmetry_3 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_3_1")], model.selection("VERTEX", "Box_3_1/Front&Box_3_1/Right&Box_3_1/Top"))
-Symmetry_4 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_4_1")], model.selection("VERTEX", "Sketch_1/Vertex-SketchLine_1e"))
-Symmetry_5 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_5_1")], model.selection("VERTEX", "Vertex_1_1"))
-Symmetry_6 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_6_1")], model.selection("VERTEX", "InvalidName"))
-
-Symmetry_7 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_7_1")], model.selection("EDGE", "PartSet/OZ"))
-Symmetry_8 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_8_1")], model.selection("EDGE", "Axis_1"))
-Symmetry_9 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_9_1")], model.selection("EDGE", "Box_9_1/Front&Box_9_1/Top"))
-Symmetry_10 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_10_1")], model.selection("EDGE", "Sketch_1/Edge-SketchLine_1"))
-Symmetry_11 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_11_1")], model.selection("EDGE", "Edge_1_1"))
-Symmetry_12 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_12_1")], model.selection("EDGE", "InvalidName"))
-
-Symmetry_13 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_13_1")], model.selection("FACE", "PartSet/XOY"))
-Symmetry_14 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_14_1")], model.selection("FACE", "Plane_1"))
-Symmetry_15 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_15_1")], model.selection("FACE", "Box_15_1/Front"))
-Symmetry_16 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_16_1")], model.selection("FACE", "Face_1_1"))
-Symmetry_17 = model.addMirror(Part_1_doc, [model.selection("SOLID", "Box_17_1")], model.selection("FACE", "InvalidName"))
-Symmetry_18 = model.addMirror(Part_1_doc, [model.selection("SHELL", "Extrusion_1_1")], model.selection("FACE", "Plane_2"))
+Symmetry_1 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_1_1")], model.selection("VERTEX", "PartSet/Origin"))
+Symmetry_2 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_2_1")], model.selection("VERTEX", "Point_1"))
+Symmetry_3 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_3_1")], model.selection("VERTEX", "Box_3_1/Front&Box_3_1/Right&Box_3_1/Top"))
+Symmetry_4 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_4_1")], model.selection("VERTEX", "Sketch_1/Vertex-SketchLine_1e"))
+Symmetry_5 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_5_1")], model.selection("VERTEX", "Vertex_1_1"))
+Symmetry_6 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_6_1")], model.selection("VERTEX", "InvalidName"))
+Symmetry_7 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_7_1")], model.selection("VERTEX", "PartSet/Origin"), False)
+
+Symmetry_8 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_8_1")], model.selection("EDGE", "PartSet/OZ"))
+Symmetry_9 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_9_1")], model.selection("EDGE", "Axis_1"))
+Symmetry_10 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_10_1")], model.selection("EDGE", "Box_9_1/Front&Box_9_1/Top"))
+Symmetry_11 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_11_1")], model.selection("EDGE", "Sketch_1/Edge-SketchLine_1"))
+Symmetry_12 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_12_1")], model.selection("EDGE", "Edge_1_1"))
+Symmetry_13 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_13_1")], model.selection("EDGE", "InvalidName"))
+Symmetry_14 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_14_1")], model.selection("EDGE", "PartSet/OZ"), False)
+
+Symmetry_15 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_15_1")], model.selection("FACE", "PartSet/XOY"))
+Symmetry_16 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_16_1")], model.selection("FACE", "Plane_1"))
+Symmetry_17 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_17_1")], model.selection("FACE", "Box_15_1/Front"))
+Symmetry_18 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_18_1")], model.selection("FACE", "Face_1_1"))
+Symmetry_19 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_19_1")], model.selection("FACE", "InvalidName"))
+Symmetry_20 = model.addSymmetry(Part_1_doc, [model.selection("SOLID", "Box_20_1")], model.selection("FACE", "PartSet/XOY"), False)
+Symmetry_21 = model.addSymmetry(Part_1_doc, [model.selection("SHELL", "Extrusion_1_1")], model.selection("FACE", "Plane_2"))
 
 model.do()
 model.end()
@@ -162,9 +168,9 @@ model.testNbSubShapes(Symmetry_5, GeomAPI_Shape.FACE, [12])
 model.testHaveNamingFaces(Symmetry_5, model, Part_1_doc)
 
 model.testNbResults(Symmetry_7, 1)
-model.testNbSubResults(Symmetry_7, [2])
-model.testNbSubShapes(Symmetry_7, GeomAPI_Shape.SOLID, [2])
-model.testNbSubShapes(Symmetry_7, GeomAPI_Shape.FACE, [12])
+model.testNbSubResults(Symmetry_7, [0])
+model.testNbSubShapes(Symmetry_7, GeomAPI_Shape.SOLID, [1])
+model.testNbSubShapes(Symmetry_7, GeomAPI_Shape.FACE, [6])
 model.testHaveNamingFaces(Symmetry_7, model, Part_1_doc)
 
 model.testNbResults(Symmetry_8, 1)
@@ -191,16 +197,16 @@ model.testNbSubShapes(Symmetry_11, GeomAPI_Shape.SOLID, [2])
 model.testNbSubShapes(Symmetry_11, GeomAPI_Shape.FACE, [12])
 model.testHaveNamingFaces(Symmetry_11, model, Part_1_doc)
 
-model.testNbResults(Symmetry_13, 1)
-model.testNbSubResults(Symmetry_13, [2])
-model.testNbSubShapes(Symmetry_13, GeomAPI_Shape.SOLID, [2])
-model.testNbSubShapes(Symmetry_13, GeomAPI_Shape.FACE, [12])
-model.testHaveNamingFaces(Symmetry_13, model, Part_1_doc)
+model.testNbResults(Symmetry_12, 1)
+model.testNbSubResults(Symmetry_12, [2])
+model.testNbSubShapes(Symmetry_12, GeomAPI_Shape.SOLID, [2])
+model.testNbSubShapes(Symmetry_12, GeomAPI_Shape.FACE, [12])
+model.testHaveNamingFaces(Symmetry_12, model, Part_1_doc)
 
 model.testNbResults(Symmetry_14, 1)
-model.testNbSubResults(Symmetry_14, [2])
-model.testNbSubShapes(Symmetry_14, GeomAPI_Shape.SOLID, [2])
-model.testNbSubShapes(Symmetry_14, GeomAPI_Shape.FACE, [12])
+model.testNbSubResults(Symmetry_14, [0])
+model.testNbSubShapes(Symmetry_14, GeomAPI_Shape.SOLID, [1])
+model.testNbSubShapes(Symmetry_14, GeomAPI_Shape.FACE, [6])
 model.testHaveNamingFaces(Symmetry_14, model, Part_1_doc)
 
 model.testNbResults(Symmetry_15, 1)
@@ -215,18 +221,36 @@ model.testNbSubShapes(Symmetry_16, GeomAPI_Shape.SOLID, [2])
 model.testNbSubShapes(Symmetry_16, GeomAPI_Shape.FACE, [12])
 model.testHaveNamingFaces(Symmetry_16, model, Part_1_doc)
 
+model.testNbResults(Symmetry_17, 1)
+model.testNbSubResults(Symmetry_17, [2])
+model.testNbSubShapes(Symmetry_17, GeomAPI_Shape.SOLID, [2])
+model.testNbSubShapes(Symmetry_17, GeomAPI_Shape.FACE, [12])
+model.testHaveNamingFaces(Symmetry_17, model, Part_1_doc)
+
+model.testNbResults(Symmetry_18, 1)
+model.testNbSubResults(Symmetry_18, [2])
+model.testNbSubShapes(Symmetry_18, GeomAPI_Shape.SOLID, [2])
+model.testNbSubShapes(Symmetry_18, GeomAPI_Shape.FACE, [12])
+model.testHaveNamingFaces(Symmetry_18, model, Part_1_doc)
+
+model.testNbResults(Symmetry_20, 1)
+model.testNbSubResults(Symmetry_20, [0])
+model.testNbSubShapes(Symmetry_20, GeomAPI_Shape.SOLID, [1])
+model.testNbSubShapes(Symmetry_20, GeomAPI_Shape.FACE, [6])
+model.testHaveNamingFaces(Symmetry_20, model, Part_1_doc)
+
 model.testNbResults(Symmetry_6, 0)
 assert(Symmetry_6.feature().error() == 'Attribute "point_object" is not initialized.')
 
-model.testNbResults(Symmetry_12, 0)
-assert(Symmetry_12.feature().error() == 'Attribute "axis_object" is not initialized.')
+model.testNbResults(Symmetry_13, 0)
+assert(Symmetry_13.feature().error() == 'Attribute "axis_object" is not initialized.')
 
-model.testNbResults(Symmetry_17, 0)
-assert(Symmetry_17.feature().error() == 'Attribute "plane_object" is not initialized.')
+model.testNbResults(Symmetry_19, 0)
+assert(Symmetry_19.feature().error() == 'Attribute "plane_object" is not initialized.')
 
-model.testNbResults(Symmetry_18, 1)
-model.testNbSubResults(Symmetry_18, [2])
-model.testNbSubShapes(Symmetry_18, GeomAPI_Shape.SOLID, [0])
-model.testNbSubShapes(Symmetry_18, GeomAPI_Shape.SHELL, [2])
-model.testNbSubShapes(Symmetry_18, GeomAPI_Shape.FACE, [10])
-model.testHaveNamingFaces(Symmetry_18, model, Part_1_doc)
+model.testNbResults(Symmetry_21, 1)
+model.testNbSubResults(Symmetry_21, [2])
+model.testNbSubShapes(Symmetry_21, GeomAPI_Shape.SOLID, [0])
+model.testNbSubShapes(Symmetry_21, GeomAPI_Shape.SHELL, [2])
+model.testNbSubShapes(Symmetry_21, GeomAPI_Shape.FACE, [10])
+model.testHaveNamingFaces(Symmetry_21, model, Part_1_doc)