This commit is contained in:
Dion Moult
2023-05-26 19:24:14 +10:00
parent e4ff87cb01
commit 43bfd51ccb
6 changed files with 37 additions and 7 deletions
@@ -74,6 +74,21 @@ Scenario: Remove drawing - via object deletion
When I press "bim.override_object_delete"
Then the collection "IfcGroup/PLAN_VIEW" does not exist
Scenario: Remove drawing - deleting active drawing
Given an empty IFC project
And I add a cube
And the object "Cube" is selected
And I set "scene.BIMRootProperties.ifc_class" to "IfcWall"
And I press "bim.assign_class"
And the variable "wall1" is "IfcStore.get_file().by_type('IfcWall')[-1].id()"
And I press "bim.add_drawing"
And the variable "drawing" is "IfcStore.get_file().by_type('IfcAnnotation')[0].id()"
And I set "scene.DocProperties.active_drawing_index" to "0"
And I press "bim.activate_drawing(drawing={drawing})"
And the object "IfcAnnotation/PLAN_VIEW" is selected
When I press "bim.override_object_delete"
Then the collection "IfcGroup/PLAN_VIEW" does not exist
Scenario: Reproducing freeze on generating drawing - Issue 3169
Given an empty IFC project
And I add a cube
+2
View File
@@ -345,6 +345,8 @@ class TestDuplicateDrawing:
class TestRemoveDrawing:
def test_run(self, ifc, drawing):
drawing.is_active_drawing("drawing").should_be_called().will_return(True)
drawing.run_drawing_activate_model().should_be_called()
drawing.get_drawing_collection("drawing").should_be_called().will_return("collection")
drawing.get_drawing_group("drawing").should_be_called().will_return("group")
drawing.get_group_elements("group").should_be_called().will_return("elements")