merge linked names correctly into namedetails

Convert the '_place_*' entries back to normal entries before
returning them in the 'namedetails' section. If the name field is
duplicated, kept the '_place_*' notation. This preserves the previous
behaviour before _place_ names were introduces but adds the additional
names from the linked place for reference.
This commit is contained in:
Sarah Hoffmann
2022-03-17 11:02:02 +01:00
parent 524dc64ab7
commit e133476c35
3 changed files with 39 additions and 11 deletions

View File

@@ -102,6 +102,9 @@ class GenericResponse:
elif value.startswith("^"):
assert re.fullmatch(value, self.result[idx][field]), \
BadRowValueAssert(self, idx, field, value)
elif isinstance(self.result[idx][field], OrderedDict):
assert self.result[idx][field] == eval('{' + value + '}'), \
BadRowValueAssert(self, idx, field, value)
else:
assert str(self.result[idx][field]) == str(value), \
BadRowValueAssert(self, idx, field, value)