mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-10 14:07:43 +00:00
Drawing collection hierarchy is now auto fixed if shuffled around manually. See #1153.
This commit is contained in:
@@ -215,6 +215,18 @@ class TestAssign(NewFile):
|
||||
assert axis_obj.users_collection[0].name == "UAxes"
|
||||
assert bpy.data.collections.get("IfcGrid/Name").children.get("UAxes")
|
||||
|
||||
def test_in_decomposition_mode_drawings_are_placed_in_a_group_in_a_views_collection(self):
|
||||
bpy.ops.bim.create_project()
|
||||
element_obj = bpy.data.objects.new("IfcAnnotation/Name", None)
|
||||
element = tool.Ifc.get().createIfcAnnotation(ObjectType="DRAWING")
|
||||
tool.Ifc.link(element, element_obj)
|
||||
group = ifcopenshell.api.run("group.add_group", tool.Ifc.get())
|
||||
ifcopenshell.api.run("group.assign_group", tool.Ifc.get(), product=element, group=group)
|
||||
subject.assign(element_obj)
|
||||
assert element_obj.users_collection[0].name == "IfcGroup/Unnamed"
|
||||
assert bpy.data.collections.get("Views").children.get("IfcGroup/Unnamed")
|
||||
assert bpy.data.collections.get("IfcProject/My Project").children.get("Views")
|
||||
|
||||
|
||||
class TestSync(NewFile):
|
||||
def test_in_decomposition_mode_elements_can_be_in_spatial_containers(self):
|
||||
|
||||
Reference in New Issue
Block a user