mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-08 05:16:25 +00:00
fix linked ifc selectability toggle
This commit is contained in:
@@ -329,6 +329,16 @@ Scenario: Toggle link visibility - wireframe mode
|
||||
Then "scene.BIMProjectProperties.links['{cwd}/test/files/basic.ifc'].is_wireframe" is "False"
|
||||
And the object "Chunk" should display as "TEXTURED"
|
||||
|
||||
Scenario: Toggle link selectability
|
||||
Given an empty IFC project
|
||||
And I press "bim.link_ifc(filepath='{cwd}/test/files/basic.ifc')"
|
||||
When I press "bim.toggle_link_selectability(link='{cwd}/test/files/basic.ifc')"
|
||||
Then "scene.BIMProjectProperties.links['{cwd}/test/files/basic.ifc'].is_selectable" is "False"
|
||||
And the collection "IfcProject/basic.ifc" is unselectable
|
||||
When I press "bim.toggle_link_selectability(link='{cwd}/test/files/basic.ifc')"
|
||||
Then "scene.BIMProjectProperties.links['{cwd}/test/files/basic.ifc'].is_selectable" is "True"
|
||||
And the collection "IfcProject/basic.ifc" is selectable
|
||||
|
||||
Scenario: Toggle link visibility - visible mode
|
||||
Given an empty IFC project
|
||||
And I press "bim.link_ifc(filepath='{cwd}/test/files/basic.ifc')"
|
||||
|
||||
@@ -397,6 +397,18 @@ def the_collection_name_exists(name) -> bpy.types.Collection:
|
||||
return obj
|
||||
|
||||
|
||||
@then(parsers.parse('the collection "{name}" is selectable'))
|
||||
def the_collection_name_is_selectable(name: str) -> None:
|
||||
col = the_collection_name_exists(name)
|
||||
assert col.hide_select == False
|
||||
|
||||
|
||||
@then(parsers.parse('the collection "{name}" is unselectable'))
|
||||
def the_collection_name_is_unselectable(name: str) -> None:
|
||||
col = the_collection_name_exists(name)
|
||||
assert col.hide_select == True
|
||||
|
||||
|
||||
@then(parsers.parse('the collection "{name}" exists in viewlayer'))
|
||||
def the_collection_exists_in_viewlayer(name: str) -> bpy.types.LayerCollection:
|
||||
col = the_collection_name_exists(name)
|
||||
|
||||
Reference in New Issue
Block a user