Salome HOME
Fix for #2834 : In Test2290.py, names have not been updated in group
authormpv <mpv@opencascade.com>
Fri, 11 Jan 2019 13:31:09 +0000 (16:31 +0300)
committermpv <mpv@opencascade.com>
Fri, 11 Jan 2019 13:31:09 +0000 (16:31 +0300)
src/ExchangePlugin/Test/Test2290.py
src/Model/Model_AttributeSelection.cpp

index 04a0ca50ae5fec253972c6ffef9e84b621c9e1a1..4136c034ffb6ac37b16df0970a64114371681986 100644 (file)
@@ -27,8 +27,12 @@ Part_1_doc = Part_1.document()
 Box_1 = model.addBox(Part_1_doc, 5, 10, 10)
 Box_2 = model.addBox(Part_1_doc, 10, 50, 8)
 Partition_1 = model.addPartition(Part_1_doc, [model.selection("SOLID", "Box_2_1"), model.selection("SOLID", "Box_1_1")])
-Group_1 = model.addGroup(Part_1_doc, [model.selection("FACE", "Partition_1_1_3/Modified_Face_2_3"), model.selection("FACE", "Partition_1_1_1/Modified_Face_2_3")])
+Group_1 = model.addGroup(Part_1_doc, [model.selection("FACE", "Partition_1_1_1/Modified_Face&Box_1_1/Left&Box_2_1/Left"), model.selection("FACE", "Partition_1_1_3/Modified_Face&Box_1_1/Front")])
 model.do()
+
+from ModelAPI import *
+aFactory = ModelAPI_Session.get().validators()
+assert(aFactory.validate(Group_1.feature()))
 # test export to XAO
 anExportFeature = Part_1_doc.addFeature("Export")
 anExportFeature.string("xao_file_path").setValue("Data/export2290.xao")
index 5a1bdec60d58670378a58d0abe027a662175de50..00736a73ece411591afd7cc6d08e054c99c310f7 100644 (file)
@@ -1374,7 +1374,6 @@ void Model_AttributeSelection::updateInHistory()
       }
 
       ResultPtr aSetContext;
-      AttributeSelectionPtr aSetAttr;
       if (aFirst) {
         setValue(*aNewCont, aValueShape);
         aSetContext = context();