From: azv Date: Fri, 17 Nov 2017 12:52:53 +0000 (+0300) Subject: Adjust models test cases X-Git-Tag: V_2.10.0RC~155^2 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=refs%2Fheads%2FDev_ResultNames;p=modules%2Fshaper.git Adjust models test cases --- diff --git a/test.models/angle30.py b/test.models/angle30.py index 8554711c9..14fbe4b70 100644 --- a/test.models/angle30.py +++ b/test.models/angle30.py @@ -619,6 +619,7 @@ SketchConstraintDistance_33 = Sketch_7.setDistance(SketchCircle_7.center(), Sket SketchConstraintDistance_34 = Sketch_7.setDistance(SketchCircle_7.center(), SketchLine_66.result(), 11) model.do() ExtrusionCut_1 = model.addExtrusionCut(Part_1_doc, [model.selection("WIRE", "Sketch_7/Wire-SketchLine_66f-SketchLine_67f-SketchLine_68f-SketchLine_60f-SketchLine_61f-SketchLine_62f-SketchLine_63f-SketchLine_64f-SketchArc_14_2r-SketchArc_15_2r"), model.selection("FACE", "Sketch_7/Face-SketchCircle_4_2f"), model.selection("FACE", "Sketch_7/Face-SketchCircle_5_2f"), model.selection("FACE", "Sketch_7/Face-SketchCircle_7_2f"), model.selection("FACE", "Sketch_7/Face-SketchCircle_6_2f")], model.selection(), 0, 10, [model.selection("SOLID", "Extrusion_8_1")]) +ExtrusionCut_1.result().setName("ExtrusionCut_1_1") Sketch_8 = model.addSketch(Part_1_doc, model.selection("FACE", "Extrusion_8_1/Generated_Face_5")) SketchLine_67 = Sketch_8.addLine(55, -34.06366588218793, 55, 66.69872981077805) SketchLine_67.setName("SketchLine_79") @@ -767,6 +768,7 @@ SketchConstraintDistance_44 = Sketch_8.setDistance(SketchArc_18.startPoint(), Sk SketchConstraintDistance_44.setName("SketchConstraintDistance_45") model.do() ExtrusionCut_2 = model.addExtrusionCut(Part_1_doc, [model.selection("FACE", "Sketch_8/Face-SketchLine_79r-SketchLine_80r-SketchLine_81r-SketchLine_73r-SketchLine_74r-SketchLine_75r-SketchLine_76r-SketchLine_77r-SketchArc_16_2r-SketchArc_17_2r"), model.selection("WIRE", "Sketch_8/Wire-SketchCircle_8_2f"), model.selection("WIRE", "Sketch_8/Wire-SketchCircle_9_2f"), model.selection("WIRE", "Sketch_8/Wire-SketchArc_19_2f-SketchArc_18_2f-SketchLine_82f-SketchLine_83r")], model.selection(), 0, 10, [model.selection("SOLID", "ExtrusionCut_1_1")]) +ExtrusionCut_2.result().setName("ExtrusionCut_2_1") Boolean_7 = model.addFuse(Part_1_doc, [model.selection("SOLID", "Boolean_6_1")], [model.selection("SOLID", "ExtrusionCut_2_1")]) Boolean_7.result().setName("Boolean_7_1") model.do() diff --git a/test.models/case24.py b/test.models/case24.py index d14e67386..c0d1c6eb3 100644 --- a/test.models/case24.py +++ b/test.models/case24.py @@ -691,7 +691,7 @@ SketchConstraintCoincidence_129 = Sketch_10.setCoincident(SketchArc_11.startPoin SketchConstraintCoincidence_129.setName("SketchConstraintCoincidence_127") SketchConstraintTangent_19 = Sketch_10.setTangent(SketchArc_11.results()[1], SketchLine_78.result()) SketchConstraintTangent_19.setName("SketchConstraintTangent_24") -SketchPoint_8 = Sketch_10.addPoint(model.selection("VERTEX", "ExtrusionCut_2_1/Modfied_9&RevolutionFuse_3_1/Modfied_7&RevolutionFuse_3_1/Modfied_8&RevolutionFuse_3_1/Modfied_24&RevolutionFuse_3_1/Modfied_9")) +SketchPoint_8 = Sketch_10.addPoint(model.selection("VERTEX", "ExtrusionCut_2_1/Modfied_5&RevolutionFuse_3_1/Modfied_7&RevolutionFuse_3_1/Modfied_8&RevolutionFuse_3_1/Modfied_24&RevolutionFuse_3_1/Modfied_9")) SketchConstraintCoincidence_130 = Sketch_10.setCoincident(SketchArc_11.endPoint(), SketchPoint_8.result()) SketchConstraintCoincidence_130.setName("SketchConstraintCoincidence_128") SketchArc_12 = Sketch_10.addArc(64.00001789135865, 23.01137360115889, 64, 20, 61.15622559702543, 22.02080994708722, True) @@ -702,7 +702,7 @@ SketchConstraintCoincidence_131 = Sketch_10.setCoincident(SketchArc_12.startPoin SketchConstraintCoincidence_131.setName("SketchConstraintCoincidence_129") SketchConstraintTangent_20 = Sketch_10.setTangent(SketchArc_12.results()[1], SketchLine_77.result()) SketchConstraintTangent_20.setName("SketchConstraintTangent_25") -SketchPoint_9 = Sketch_10.addPoint(model.selection("VERTEX", "ExtrusionCut_2_1/Modfied_9&RevolutionFuse_3_1/Modfied_3&RevolutionFuse_3_1/Modfied_4&RevolutionFuse_3_1/Modfied_24&RevolutionFuse_3_1/Modfied_5")) +SketchPoint_9 = Sketch_10.addPoint(model.selection("VERTEX", "ExtrusionCut_2_1/Modfied_5&RevolutionFuse_3_1/Modfied_3&RevolutionFuse_3_1/Modfied_4&RevolutionFuse_3_1/Modfied_24&RevolutionFuse_3_1/Modfied_5")) SketchConstraintCoincidence_132 = Sketch_10.setCoincident(SketchArc_12.endPoint(), SketchPoint_9.result()) SketchConstraintCoincidence_132.setName("SketchConstraintCoincidence_130") SketchLine_79 = Sketch_10.addLine(61.15622559702543, 22.02080994708722, 59.81204392543111, 22.0208099470871) @@ -771,6 +771,7 @@ SketchArc_13.result().setName("SketchArc_16") SketchArc_13.results()[1].setName("SketchArc_16_2") model.do() ExtrusionFuse_3 = model.addExtrusionFuse(Part_1_doc, [model.selection("FACE", "Sketch_10/Face-SketchArc_16_2f-SketchLine_81r-SketchLine_82f-SketchArc_17_2r-SketchLine_83f-SketchLine_84f-SketchLine_85r-SketchArc_18_2r"), model.selection("FACE", "Sketch_10/Face-SketchArc_19_2f-SketchLine_86r-SketchLine_87f-SketchArc_20_2r-SketchLine_88f-SketchLine_89f-SketchLine_90r-SketchArc_21_2r")], model.selection(), 20, 0, [model.selection("SOLID", "ExtrusionCut_2_1")]) +ExtrusionFuse_3.result().setName("ExtrusionFuse_3_1") Sketch_11 = model.addSketch(Part_1_doc, model.selection("FACE", "PartSet/XOY")) SketchCircle_2 = Sketch_11.addCircle(89, 0, 6) SketchPoint_11 = Sketch_11.addPoint(model.selection("VERTEX", "Sketch_2/Vertex-SketchPoint_1-SketchLine_10s-SketchLine_9e")) @@ -792,7 +793,9 @@ model.do() RevolutionCut_1 = model.addRevolutionCut(Part_1_doc, [model.selection("COMPOUND", "Sketch_9")], model.selection("EDGE", "PartSet/OZ"), 0, 360, [model.selection("SOLID", "ExtrusionFuse_3_1")]) RevolutionCut_1.result().setName("RevolutionCut_1_1") ExtrusionCut_3 = model.addExtrusionCut(Part_1_doc, [model.selection("WIRE", "Sketch_11/Wire-SketchCircle_4_2f"), model.selection("WIRE", "Sketch_11/Wire-SketchCircle_3_2f"), model.selection("WIRE", "Sketch_11/Wire-SketchCircle_5_2f")], model.selection(), 30, -15, [model.selection("SOLID", "RevolutionCut_1_1")]) +ExtrusionCut_3.result().setName("ExtrusionCut_3_1") ExtrusionCut_4 = model.addExtrusionCut(Part_1_doc, [model.selection("WIRE", "Sketch_11/Wire-SketchCircle_2_2f"), model.selection("FACE", "Sketch_11/Face-SketchCircle_6_2f"), model.selection("WIRE", "Sketch_11/Wire-SketchCircle_7_2f")], model.selection(), 30, 2, [model.selection("SOLID", "ExtrusionCut_3_1")]) +ExtrusionCut_4.result().setName("ExtrusionCut_4_1") # Test reexecution after parameter change Parameter_R.setValue(5) diff --git a/test.models/clothespin.py b/test.models/clothespin.py index fa64ebb96..66761864d 100644 --- a/test.models/clothespin.py +++ b/test.models/clothespin.py @@ -320,6 +320,7 @@ SketchConstraintCoincidence_54.setName("SketchConstraintCoincidence_58") SketchConstraintEqual_2 = Sketch_3.setEqual(SketchLine_30.result(), SketchLine_25.result()) model.do() ExtrusionCut_2 = model.addExtrusionCut(Part_1_doc, [model.selection("FACE", "Sketch_3/Face-SketchLine_32f-SketchLine_33f-SketchLine_34f-SketchLine_35f"), model.selection("FACE", "Sketch_3/Face-SketchLine_26f-SketchLine_27f-SketchLine_28f-SketchLine_29f")], model.selection(), model.selection("FACE", "ExtrusionCut_1_1/Modfied_3"), 0, model.selection(), 0, [model.selection("SOLID", "ExtrusionCut_1_1")]) +ExtrusionCut_2.result().setName("ExtrusionCut_2_1") Sketch_4 = model.addSketch(Part_1_doc, model.selection("FACE", "ExtrusionCut_1_1/Modfied_1")) SketchLine_37 = Sketch_4.addLine(0.4324637622511017, 3.581086955422081, 1.55585595716119, 2.812450190483599) SketchLine_37.setName("SketchLine_39") @@ -1260,6 +1261,7 @@ SketchConstraintCoincidence_227.setName("SketchConstraintCoincidence_58") SketchConstraintEqual_5 = Sketch_13.setEqual(SketchLine_136.result(), SketchLine_131.result()) model.do() ExtrusionCut_11 = model.addExtrusionCut(Part_2_doc, [model.selection("FACE", "Sketch_3/Face-SketchLine_32f-SketchLine_33f-SketchLine_34f-SketchLine_35f"), model.selection("FACE", "Sketch_3/Face-SketchLine_26f-SketchLine_27f-SketchLine_28f-SketchLine_29f")], model.selection(), model.selection("FACE", "ExtrusionCut_1_1/Modfied_3"), 0, model.selection(), 0, [model.selection("SOLID", "ExtrusionCut_1_1")]) +ExtrusionCut_11.result().setName("ExtrusionCut_2_1") Sketch_14 = model.addSketch(Part_2_doc, model.selection("FACE", "ExtrusionCut_1_1/Modfied_1")) SketchLine_143 = Sketch_14.addLine(0.4324637622511017, 3.581086955422081, 1.55585595716119, 2.812450190483599) SketchLine_143.setName("SketchLine_39") diff --git a/test.models/ecran.py b/test.models/ecran.py index 8dbc307d9..5bd402786 100644 --- a/test.models/ecran.py +++ b/test.models/ecran.py @@ -511,6 +511,7 @@ model.do() Sketch_5.setName("Sketch_6") Sketch_5.result().setName("Sketch_6") ExtrusionCut_4 = model.addExtrusionCut(Part_1_doc, [model.selection("WIRE", "Sketch_6/Wire-SketchArc_9_2f-SketchArc_10_2f-SketchLine_73r-SketchLine_74r-SketchLine_75r-SketchLine_76r"), model.selection("WIRE", "Sketch_6/Wire-SketchLine_58f-SketchLine_61f-SketchLine_60f-SketchLine_51f-SketchArc_4_2f-SketchArc_5_2f"), model.selection("WIRE", "Sketch_6/Wire-SketchLine_57f-SketchLine_47f-SketchLine_62f-SketchLine_63f-SketchArc_3_2f-SketchArc_6_2f")], model.selection(), 0, 10, [model.selection("SOLID", "ExtrusionCut_3_1")]) +ExtrusionCut_4.result().setName("ExtrusionCut_4_1") Sketch_6 = model.addSketch(Part_1_doc, model.selection("FACE", "ExtrusionCut_4_1/Modfied_1")) SketchArc_11 = Sketch_6.addArc(44.89, -23.54999053274703, 43.89, -23.54999053274703, 44.89, -22.54999053274703, False) SketchArc_12 = Sketch_6.addArc(44.89, -13.54999053274703, 44.89, -14.54999053274703, 43.89, -13.54999053274703, False) @@ -847,6 +848,7 @@ model.do() Sketch_6.setName("Sketch_7") Sketch_6.result().setName("Sketch_7") ExtrusionCut_5 = model.addExtrusionCut(Part_1_doc, [model.selection("WIRE", "Sketch_7/Wire-SketchArc_20_2f-SketchArc_21_2f-SketchArc_22_2f-SketchArc_23_2f-SketchLine_91r-SketchLine_92f-SketchLine_93r-SketchLine_94f"), model.selection("WIRE", "Sketch_7/Wire-SketchArc_52_2f-SketchArc_53_2f-SketchArc_56_2f-SketchArc_57_2f-SketchLine_114r-SketchLine_115f-SketchLine_116r-SketchLine_121f"), model.selection("WIRE", "Sketch_7/Wire-SketchArc_44_2f-SketchArc_45_2f-SketchArc_48_2f-SketchArc_49_2f-SketchLine_107f-SketchLine_113f-SketchLine_117r-SketchLine_123r"), model.selection("WIRE", "Sketch_7/Wire-SketchArc_16_2f-SketchArc_17_2f-SketchArc_18_2f-SketchArc_19_2f-SketchLine_87f-SketchLine_88f-SketchLine_89r-SketchLine_90r"), model.selection("WIRE", "Sketch_7/Wire-SketchArc_11_2f-SketchArc_12_2f-SketchArc_14_2f-SketchLine_81f-SketchLine_82r-SketchLine_83f-SketchLine_84r-SketchArc_15_2f"), model.selection("WIRE", "Sketch_7/Wire-SketchArc_36_2f-SketchArc_38_2f-SketchArc_40_2f-SketchArc_41_2f-SketchLine_108r-SketchLine_119r-SketchLine_127f-SketchLine_129f"), model.selection("WIRE", "Sketch_7/Wire-SketchArc_37_2f-SketchArc_39_2f-SketchArc_42_2f-SketchArc_43_2f-SketchLine_118r-SketchLine_120f-SketchLine_122r-SketchLine_130f"), model.selection("WIRE", "Sketch_7/Wire-SketchArc_24_2f-SketchArc_25_2f-SketchArc_26_2f-SketchArc_27_2f-SketchLine_98f-SketchLine_100r-SketchLine_101f-SketchLine_103r"), model.selection("WIRE", "Sketch_7/Wire-SketchArc_30_2f-SketchArc_31_2f-SketchArc_34_2f-SketchArc_35_2f-SketchLine_95f-SketchLine_96r-SketchLine_97f-SketchLine_105r"), model.selection("WIRE", "Sketch_7/Wire-SketchArc_46_2f-SketchArc_47_2f-SketchArc_50_2f-SketchArc_51_2f-SketchLine_124f-SketchLine_125r-SketchLine_126f-SketchLine_128r"), model.selection("WIRE", "Sketch_7/Wire-SketchArc_54_2f-SketchArc_55_2f-SketchArc_58_2f-SketchArc_59_2f-SketchLine_109f-SketchLine_110r-SketchLine_111r-SketchLine_112f"), model.selection("WIRE", "Sketch_7/Wire-SketchArc_28_2f-SketchArc_29_2f-SketchArc_32_2f-SketchArc_33_2f-SketchLine_99r-SketchLine_102f-SketchLine_104f-SketchLine_106r")], model.selection(), 0, 10, [model.selection("SOLID", "ExtrusionCut_4_1")]) +ExtrusionCut_5.result().setName("ExtrusionCut_5_1") Sketch_7 = model.addSketch(Part_1_doc, model.selection("FACE", "ExtrusionCut_5_1/Modfied_1")) SketchLine_126 = Sketch_7.addLine(-153.5, -37.049990532747, -152.3000099350335, -37.0499905327475) SketchLine_126.setName("SketchLine_135") @@ -1065,6 +1067,7 @@ model.do() Sketch_8.setName("Sketch_9") Sketch_8.result().setName("Sketch_9") ExtrusionCut_7 = model.addExtrusionCut(Part_1_doc, [model.selection("FACE", "Sketch_9/Face-SketchLine_147f-SketchLine_148f-SketchArc_64_2f-SketchArc_65_2f"), model.selection("FACE", "Sketch_9/Face-SketchLine_139f-SketchLine_141f-SketchArc_63_2f-SketchArc_62_2f"), model.selection("FACE", "Sketch_9/Face-SketchArc_66_2f-SketchArc_67_2f-SketchLine_149r-SketchLine_150r")], model.selection(), 0, 10, [model.selection("SOLID", "ExtrusionCut_6_1")]) +ExtrusionCut_7.result().setName("ExtrusionCut_7_1") model.do() # Test reexecution after parameter change diff --git a/test.models/piece_02.py b/test.models/piece_02.py index 9ca1d6335..92d8e891f 100644 --- a/test.models/piece_02.py +++ b/test.models/piece_02.py @@ -129,6 +129,7 @@ SketchConstraintRadius_3 = Sketch_2.setRadius(SketchCircle_2.results()[1], 2.5) SketchConstraintDistance_3 = Sketch_2.setDistance(SketchLine_12.result(), SketchCircle_4.center(), 8) model.do() ExtrusionCut_1 = model.addExtrusionCut(Part_1_doc, [model.selection("WIRE", "Sketch_2/Wire-SketchCircle_1_2f"), model.selection("WIRE", "Sketch_2/Wire-SketchCircle_2_2r"), model.selection("WIRE", "Sketch_2/Wire-SketchCircle_3_2f")], model.selection(), 0, 15, [model.selection("SOLID", "Extrusion_1_1")]) +ExtrusionCut_1.result().setName("ExtrusionCut_1_1") ExtrusionCut_2 = model.addExtrusionCut(Part_1_doc, [model.selection("FACE", "Sketch_2/Face-SketchCircle_4_2f")], model.selection(), model.selection("FACE", "Extrusion_1_1/From_Face_1"), 0, model.selection(), 0, [model.selection("SOLID", "ExtrusionCut_1_1")]) ExtrusionCut_2.result().setName("ExtrusionCut_2_1") Sketch_3 = model.addSketch(Part_1_doc, model.defaultPlane("XOZ")) @@ -372,6 +373,8 @@ ExtrusionCut_4 = model.addExtrusionCut(Part_1_doc, [model.selection("WIRE", "Ske ExtrusionCut_4.result().setName("ExtrusionCut_4_1") ExtrusionCut_4.results()[1].setName("ExtrusionCut_4_2") ExtrusionCut_5 = model.addExtrusionCut(Part_1_doc, [model.selection("FACE", "Sketch_5/Face-SketchCircle_8_2f"), model.selection("FACE", "Sketch_5/Face-SketchCircle_9_2f")], model.selection(), 0, 20, [model.selection("SOLID", "ExtrusionCut_4_1"), model.selection("SOLID", "ExtrusionCut_4_2")]) +ExtrusionCut_5.result().setName("ExtrusionCut_5_1") +ExtrusionCut_5.results()[1].setName("ExtrusionCut_5_2") Sketch_6 = model.addSketch(Part_1_doc, model.selection("FACE", "PartSet/YOZ")) SketchLine_38 = Sketch_6.addLine(-59, 44, -59, 2) SketchLine_38.setName("SketchLine_39") diff --git a/test.models/piece_09.py b/test.models/piece_09.py index b4e332bc7..7af290633 100644 --- a/test.models/piece_09.py +++ b/test.models/piece_09.py @@ -376,6 +376,7 @@ SketchConstraintMirror_2 = Sketch_7.addMirror(SketchLine_59.result(), SketchCons [SketchArc_17, SketchLine_63, SketchLine_64, SketchArc_18, SketchLine_65, SketchLine_66] = SketchConstraintMirror_2.mirrored() model.do() ExtrusionCut_5 = model.addExtrusionCut(Part_1_doc, [model.selection("WIRE", "Sketch_7/Wire-SketchArc_16_2r-SketchLine_61f-SketchLine_62r"), model.selection("FACE", "Sketch_7/Face-SketchArc_18_2r-SketchLine_65f-SketchLine_66r"), model.selection("FACE", "Sketch_7/Face-SketchArc_17_2r-SketchLine_64r-SketchLine_66r"), model.selection("WIRE", "Sketch_7/Wire-SketchArc_15_2r-SketchLine_54f-SketchLine_55r")], model.selection(), model.selection("FACE", "Extrusion_1_1/Generated_Face_10"), 0, model.selection(), 0, [model.selection("SOLID", "ExtrusionCut_4_1")]) +ExtrusionCut_5.result().setName("ExtrusionCut_5_1") Boolean_1 = model.addFuse(Part_1_doc, [model.selection("SOLID", "ExtrusionCut_5_1")], [model.selection("SOLID", "Extrusion_3_1"), model.selection("SOLID", "ExtrusionCut_3_1")]) Boolean_1.result().setName("Boolean_1_1") model.do()