mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-11 18:16:40 +00:00
bimtester: fix in report creation on empty steps
This commit is contained in:
committed by
Dion Moult
parent
b3d180a288
commit
7bb5860200
@@ -107,6 +107,13 @@ def generate_report(adir="."):
|
||||
for scenario in feature["elements"]:
|
||||
steps = []
|
||||
total_duration = 0
|
||||
if len(scenario["steps"]) == 0:
|
||||
print(
|
||||
"Scenario '{}' in feature '{}' has no steps. "
|
||||
"Thus skipped in report."
|
||||
.format(scenario["name"], feature["name"])
|
||||
)
|
||||
continue
|
||||
for step in scenario["steps"]:
|
||||
if "result" in step:
|
||||
total_duration += step["result"]["duration"]
|
||||
|
||||
Reference in New Issue
Block a user