mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-12 06:32:09 +00:00
Add sentences to exempt IFC files from BIMTester auditing
This commit is contained in:
@@ -58,7 +58,7 @@ class TestPurger:
|
|||||||
with open(filename, 'w') as new_file:
|
with open(filename, 'w') as new_file:
|
||||||
for line in old_file:
|
for line in old_file:
|
||||||
is_purged = False
|
is_purged = False
|
||||||
if 'Given the IFC file ' in line:
|
if 'Given the IFC file ' in line and 'exists' not in line:
|
||||||
filename = line.split('"')[1]
|
filename = line.split('"')[1]
|
||||||
print('Loading file {} ...'.format(filename))
|
print('Loading file {} ...'.format(filename))
|
||||||
self.file = ifcopenshell.open(filename)
|
self.file = ifcopenshell.open(filename)
|
||||||
|
|||||||
@@ -16,6 +16,10 @@ class IfcFile(object):
|
|||||||
def step_impl(context, file):
|
def step_impl(context, file):
|
||||||
IfcFile.load(file)
|
IfcFile.load(file)
|
||||||
|
|
||||||
|
@given('the IFC file "{file}" exists')
|
||||||
|
def step_impl(context, file):
|
||||||
|
assert True
|
||||||
|
|
||||||
@given('that an IFC file is loaded')
|
@given('that an IFC file is loaded')
|
||||||
def step_impl(context):
|
def step_impl(context):
|
||||||
assert IfcFile.get()
|
assert IfcFile.get()
|
||||||
@@ -31,3 +35,7 @@ def step_impl(context, id, ifc_class):
|
|||||||
@then('the element {id} should not exist because {reason}')
|
@then('the element {id} should not exist because {reason}')
|
||||||
def step_impl(context, id, reason):
|
def step_impl(context, id, reason):
|
||||||
assert not IfcFile.get().by_id(id)
|
assert not IfcFile.get().by_id(id)
|
||||||
|
|
||||||
|
@then('the file is exempt from auditing because {reason}')
|
||||||
|
def step_impl(context, id, reason):
|
||||||
|
assert True
|
||||||
|
|||||||
Reference in New Issue
Block a user