Salome HOME
updated copyright message
[modules/shaper.git] / src / BuildPlugin / Test / TestWire.py
index 0bbbbce8fefbae0c8b8572f4b646ef490eddb5c0..d1fcacca4ed77645429fb7c074a788a6c74a175d 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (C) 2014-2019  CEA/DEN, EDF R&D
+# Copyright (C) 2014-2023  CEA, EDF
 #
 # This library is free software; you can redistribute it and/or
 # modify it under the terms of the GNU Lesser General Public
@@ -145,7 +145,7 @@ aSession.finishOperation()
 assert (len(aWireFeature2.results()) == 1)
 
 # =============================================================================
-# Test 4. Check Wire feature failed on incorrect input
+# Test 4. Check Wire feature on the whole sketch
 # =============================================================================
 
 aSession.startOperation()
@@ -153,10 +153,15 @@ aWireFeature3 = aPart.addFeature("Wire")
 aBaseObjectsList = aWireFeature3.selectionList("base_objects")
 aBaseObjectsList.append(aSketchResult, None)
 aSession.finishOperation()
-assert (len(aWireFeature3.results()) == 0)
+assert (len(aWireFeature3.results()) == 1)
+
+# =============================================================================
+# Test 5. Check Wire feature failed on incorrect input
+# =============================================================================
 
 aSession.startOperation()
-aBaseObjectsList.clear()
+aWireFeature3 = aPart.addFeature("Wire")
+aBaseObjectsList = aWireFeature3.selectionList("base_objects")
 aShapeExplorer = GeomAPI_ShapeExplorer(aBoxShape, GeomAPI_Shape.VERTEX)
 aShape = aShapeExplorer.current()
 aBaseObjectsList.append(aBoxResult, aShape)