@@ -190,13 +190,15 @@ def check_ods_sheet(sheet, account_balances, *, full):
if full:
account_bals['Unrestricted'] = unrestricted
for row in itertools.islice(sheet.getElementsByType(odf.table.TableRow), 4, None):
cells = iter(testutil.ODSCell.from_row(row))
try:
fund = next(cells).firstChild.text
except (AttributeError, StopIteration):
except AttributeError:
fund = ''
except StopIteration:
continue
balances = account_bals.pop(fund)
except KeyError:
pytest.fail(f"report included unexpected fund {fund}")
check_cell_balance(next(cells), balances['opening'])