mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-09 17:31:45 +00:00
IFC selector now uses "class" as a keyword to get the IFC class to disambiguate between "type" and "class".
This commit is contained in:
@@ -23,6 +23,11 @@ import ifcopenshell.util.selector as subject
|
||||
|
||||
|
||||
class TestGetElementValue(test.bootstrap.IFC4):
|
||||
def test_selecting_an_elements_class_or_id_using_a_query(self):
|
||||
element = ifcopenshell.api.run("root.create_entity", self.file, ifc_class="IfcWall")
|
||||
assert subject.get_element_value(element, "class") == "IfcWall"
|
||||
assert subject.get_element_value(element, "id") == element.id()
|
||||
|
||||
def test_selecting_an_elements_value_using_a_query(self):
|
||||
element = ifcopenshell.api.run("root.create_entity", self.file, ifc_class="IfcWall")
|
||||
element.Name = "Foobar"
|
||||
|
||||
Reference in New Issue
Block a user