mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-29 03:37:21 +00:00
Fix regression in split along edge
Aren't tests great
This commit is contained in:
@@ -125,7 +125,7 @@ class SplitAlongEdge(bpy.types.Operator, tool.Ifc.Operator):
|
|||||||
"Will unassign element from a type if type has a representation."
|
"Will unassign element from a type if type has a representation."
|
||||||
)
|
)
|
||||||
bl_options = {"REGISTER", "UNDO"}
|
bl_options = {"REGISTER", "UNDO"}
|
||||||
mode: bpy.props.StringProperty()
|
mode: bpy.props.StringProperty(default="BOOLEAN")
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def poll(cls, context):
|
def poll(cls, context):
|
||||||
|
|||||||
@@ -31,7 +31,7 @@ Scenario: Resize to storey
|
|||||||
When I press "bim.resize_to_storey(total_storeys=1)"
|
When I press "bim.resize_to_storey(total_storeys=1)"
|
||||||
Then nothing happens
|
Then nothing happens
|
||||||
|
|
||||||
Scenario: Split along edge
|
Scenario: Split along edge - boolean mode
|
||||||
Given an empty IFC project
|
Given an empty IFC project
|
||||||
And I add a cube
|
And I add a cube
|
||||||
And the object "Cube" is selected
|
And the object "Cube" is selected
|
||||||
@@ -41,13 +41,24 @@ Scenario: Split along edge
|
|||||||
And I add a plane of size "4" at "0,0,0"
|
And I add a plane of size "4" at "0,0,0"
|
||||||
And the object "IfcWall/Cube" is selected
|
And the object "IfcWall/Cube" is selected
|
||||||
And additionally the object "Plane" is selected
|
And additionally the object "Plane" is selected
|
||||||
When I press "bim.split_along_edge"
|
And I look at the "Miscellaneous" panel
|
||||||
|
When I click "Split Along Edge"
|
||||||
Then the object "IfcWall/Cube" is an "IfcWall"
|
Then the object "IfcWall/Cube" is an "IfcWall"
|
||||||
And the object "IfcWall/Cube.001" is an "IfcWall"
|
And the object "IfcWall/Cube.001" is an "IfcWall"
|
||||||
|
|
||||||
Scenario: Enabling and disabling IFC Sverchok
|
Scenario: Split along edge - bisect mode
|
||||||
Given an empty IFC project
|
Given an empty IFC project
|
||||||
And I press "preferences.addon_enable(module="sverchok")"
|
And I add a cube
|
||||||
And I press "preferences.addon_enable(module="ifcsverchok")"
|
And the object "Cube" is selected
|
||||||
And I press "preferences.addon_disable(module="sverchok")"
|
And I set "scene.BIMRootProperties.ifc_product" to "IfcElement"
|
||||||
And I press "preferences.addon_disable(module="ifcsverchok")"
|
And I set "scene.BIMRootProperties.ifc_class" to "IfcWall"
|
||||||
|
And I press "bim.assign_class"
|
||||||
|
And I add a plane of size "4" at "0,0,0"
|
||||||
|
And the object "IfcWall/Cube" is selected
|
||||||
|
And additionally the object "Plane" is selected
|
||||||
|
And I look at the "Miscellaneous" panel
|
||||||
|
When I click "Bisect At Faces"
|
||||||
|
Then the object "IfcWall/Cube" is an "IfcWall"
|
||||||
|
And the object "IfcWall/Cube.001" is an "IfcWall"
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -73,7 +73,7 @@ class PanelSpy:
|
|||||||
return self
|
return self
|
||||||
|
|
||||||
def __call__(self, *args, **kwargs):
|
def __call__(self, *args, **kwargs):
|
||||||
if self.spied_attr in ("row", "column", "box", "separator", "menu", "operator_menu_enum"):
|
if self.spied_attr in ("row", "column", "box", "separator", "menu", "operator_menu_enum", "split"):
|
||||||
return self
|
return self
|
||||||
elif self.spied_attr == "template_list":
|
elif self.spied_attr == "template_list":
|
||||||
listtype_name, list_id, dataptr, propname, active_dataptr, active_propname = args
|
listtype_name, list_id, dataptr, propname, active_dataptr, active_propname = args
|
||||||
|
|||||||
Reference in New Issue
Block a user