bimtester: steps, move project test into project test module

This commit is contained in:
Bernd Hahnebach
2020-12-21 16:05:06 +01:00
parent de5dc40e63
commit 8e78ed332f
2 changed files with 6 additions and 6 deletions
@@ -67,3 +67,9 @@ def get_subcontext(identifier, type, target_view):
assert False, "The subcontext with identifier {}, type {}, and target view {} could not be found".format(
identifier, type, target_view
)
@step('the project has a {attribute_name} attribute with a value of "{attribute_value}"')
def step_impl(context, attribute_name, attribute_value):
project = IfcFile.get().by_type("IfcProject")[0]
assert getattr(project, attribute_name) == attribute_value
@@ -109,12 +109,6 @@ def step_impl(context, ifc_class, qto_name, quantity_name):
use_step_matcher("parse")
@step('the project has a {attribute_name} attribute with a value of "{attribute_value}"')
def step_impl(context, attribute_name, attribute_value):
project = IfcFile.get().by_type("IfcProject")[0]
assert getattr(project, attribute_name) == attribute_value
@step('there is an {ifc_class} element with a {attribute_name} attribute with a value of "{attribute_value}"')
def step_impl(context, ifc_class, attribute_name, attribute_value):
elements = IfcFile.get().by_type(ifc_class)