mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-28 19:27:10 +00:00
BuildingSmart IFCRail changes to BIMTester (#1309)
* Add a way to validate the IFC file in BIMTester * Fix an issue in Report where only the first error was shown * Fix the usage of Schema in BIMTester * Add Aggreation steps to BIMTester
This commit is contained in:
@@ -93,9 +93,7 @@ class ReportGenerator:
|
||||
step["result"] = {}
|
||||
step["result"]["status"] = "skipped"
|
||||
step["result"]["duration"] = 0
|
||||
step["result"][
|
||||
"error_message"
|
||||
] = "This requirement has been skipped due to a previous failing step."
|
||||
step["result"]["error_message"] = "This requirement has been skipped due to a previous failing step."
|
||||
elif step["result"]["status"] == "undefined":
|
||||
step["result"] = {}
|
||||
step["result"]["status"] = "undefined"
|
||||
@@ -108,14 +106,12 @@ class ReportGenerator:
|
||||
"is_success": step["result"]["status"] == "passed",
|
||||
"is_unspecified": step["result"]["status"] == "undefined",
|
||||
"is_skipped": step["result"]["status"] == "skipped",
|
||||
"error_message": None
|
||||
if step["result"]["status"] == "passed"
|
||||
else step["result"]["error_message"],
|
||||
"error_message": None if step["result"]["status"] == "passed" else step["result"]["error_message"],
|
||||
}
|
||||
|
||||
# TODO: there is probably a better way of doing this
|
||||
if isinstance(data["error_message"], list):
|
||||
data["error_message"] = data["error_message"][1]
|
||||
# Remove the first "Assertion Failed" message
|
||||
if isinstance(data["error_message"], list) and data["error_message"]:
|
||||
data["error_message"].pop(0)
|
||||
return data
|
||||
|
||||
def get_template_strings(self):
|
||||
|
||||
Reference in New Issue
Block a user