mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-19 22:50:21 +00:00
spatial.assign_container - support batching #4474
This commit is contained in:
@@ -154,7 +154,7 @@ class TestGetContainer(NewFile):
|
||||
ifc = ifcopenshell.file()
|
||||
site = ifc.createIfcSite()
|
||||
wall = ifc.createIfcWall()
|
||||
ifcopenshell.api.run("spatial.assign_container", ifc, product=wall, relating_structure=site)
|
||||
ifcopenshell.api.run("spatial.assign_container", ifc, products=[wall], relating_structure=site)
|
||||
assert subject.get_container(wall) == site
|
||||
|
||||
|
||||
@@ -163,7 +163,7 @@ class TestGetDecomposedElements(NewFile):
|
||||
ifc = ifcopenshell.file()
|
||||
site = ifc.createIfcSite()
|
||||
wall = ifc.createIfcWall()
|
||||
ifcopenshell.api.run("spatial.assign_container", ifc, product=wall, relating_structure=site)
|
||||
ifcopenshell.api.run("spatial.assign_container", ifc, products=[wall], relating_structure=site)
|
||||
assert subject.get_decomposed_elements(site) == [wall]
|
||||
|
||||
|
||||
@@ -268,4 +268,4 @@ class TestSelectProducts(NewFile):
|
||||
bpy.context.scene.collection.objects.link(obj)
|
||||
tool.Ifc.link(product, obj)
|
||||
subject.select_products([product])
|
||||
assert obj in bpy.context.selected_objects
|
||||
assert obj in bpy.context.selected_objects
|
||||
|
||||
Reference in New Issue
Block a user