Salome HOME
Issue #2577: EDF 2018-2 Fusion of connected faces.
[modules/shaper.git] / src / BuildPlugin / Test / TestInterpolation.py
index a790170e8975b07f2fad8369c7a33166ab5d4516..656351a488264cbf118aaaafa9a8965802cb7b52 100644 (file)
@@ -58,23 +58,23 @@ Tangent_2 = model.selection("EDGE", "Sketch_1/Edge-SketchLine_2")
 Interpolation_1 = model.addInterpolation(Part_1_doc, [p_1, p_2, p_3, p_4, p_5], False, False)
 model.do()
 
-model.checkBooleansResult(Interpolation_1, model, 1, [0], [0], [0], [1], [2])
+model.checkResult(Interpolation_1, model, 1, [0], [0], [0], [1], [2])
 
-# =============================================================================
-# Test 2. Create curve 1-2-3-4-5-1, closed on, reorder off, without tangents
-# =============================================================================
+# =============================================================================
+# Test 2. Create curve 1-2-3-4-5-1, closed on, reorder off, without tangents
+# =============================================================================
 Interpolation_2 = model.addInterpolation(Part_1_doc, [p_1, p_2, p_3, p_4, p_5], True, False)
 model.do()
 
-model.checkBooleansResult(Interpolation_2, model, 1, [0], [0], [0], [1], [2])
+model.checkResult(Interpolation_2, model, 1, [0], [0], [0], [1], [2])
 
-# =============================================================================
-# Test 3. Create curve 1-2-3-4, closed off, reorder on, without tangents
-# =============================================================================
+# =============================================================================
+# Test 3. Create curve 1-2-3-4, closed off, reorder on, without tangents
+# =============================================================================
 Interpolation_3 = model.addInterpolation(Part_1_doc, [p_1, p_2, p_3, p_4], False, True)
 model.do()
 
-model.checkBooleansResult(Interpolation_3, model, 1, [0], [0], [0], [1], [2])
+model.checkResult(Interpolation_3, model, 1, [0], [0], [0], [1], [2])
 
 # =============================================================================
 # Test 4. Create curve 1-2-3-5, closed on, reorder on, without tangents
@@ -82,7 +82,7 @@ model.checkBooleansResult(Interpolation_3, model, 1, [0], [0], [0], [1], [2])
 Interpolation_4 = model.addInterpolation(Part_1_doc, [p_1, p_2, p_3, p_5], True, True)
 model.do()
 
-model.checkBooleansResult(Interpolation_4, model, 1, [0], [0], [0], [1], [2])
+model.checkResult(Interpolation_4, model, 1, [0], [0], [0], [1], [2])
 
 # =============================================================================
 # Test 5. Create curve 1-2-3-4-5, closed off, reorder off, with tangents
@@ -92,7 +92,7 @@ Interpolation_5 = model.addInterpolation(Part_1_doc, [p_1, p_2, p_3, p_4, p_5],
                                          Tangent_1, Tangent_2, False, False)
 model.do()
 
-model.checkBooleansResult(Interpolation_5, model, 1, [0], [0], [0], [1], [2])
+model.checkResult(Interpolation_5, model, 1, [0], [0], [0], [1], [2])
 
 # =============================================================================
 # Test 6. Try to create closed curve 1-2-1, closed off, reorder off, without tangents
@@ -100,8 +100,7 @@ model.checkBooleansResult(Interpolation_5, model, 1, [0], [0], [0], [1], [2])
 Interpolation_6 = model.addInterpolation(Part_1_doc, [p_1, p_2, p_1], False, False)
 model.do()
 
-# TODO uncomment
-#model.testNbResults(Interpolation_6, 0)
+model.testNbResults(Interpolation_6, 0)
 
 # =============================================================================
 # Test 7. Try to create curve on a single point 3
@@ -131,7 +130,7 @@ points = [model.selection("VERTEX", name) for name in point_names]
 Interpolation_8 = model.addInterpolation(Part_2_doc, points, False, False)
 model.do()
 
-model.checkBooleansResult(Interpolation_8, model, 1, [0], [0], [0], [1], [2])
+model.checkResult(Interpolation_8, model, 1, [0], [0], [0], [1], [2])
 
 # =============================================================================
 # Test 9. Create curve on box vertices, closed off, reorder off, with tangents
@@ -148,7 +147,7 @@ Interpolation_9 = model.addInterpolation(Part_3_doc, points,
                                          Tangent_1, Tangent_2, False, False)
 model.do()
 
-model.checkBooleansResult(Interpolation_9, model, 1, [0], [0], [0], [1], [2])
+model.checkResult(Interpolation_9, model, 1, [0], [0], [0], [1], [2])
 
 # =============================================================================
 # Test 10. Create curve using equal vertices
@@ -161,11 +160,10 @@ Point_2 = model.addPoint(Part_4_doc, 0, 0, 0)
 P_1 = model.selection("VERTEX", "Point_1")
 P_2 = model.selection("VERTEX", "Point_2")
 
-# TODO uncomment
-#Interpolation_10 = model.addInterpolation(Part_4_doc, [P_1, P_2],
-#                                          False, False)
-#model.do()
-#model.testNbResults(Interpolation_10, 0)
+Interpolation_10 = model.addInterpolation(Part_4_doc, [P_1, P_2],
+                                          False, False)
+model.do()
+model.testNbResults(Interpolation_10, 0)
 
 # =============================================================================
 # Test 11. Check subshapes naming