mypy init

This commit is contained in:
2026-10-10 17:46:16 +01:00
parent 3fab51fe70
commit 7038d8546b
3 changed files with 19 additions and 10 deletions
+10 -7
View File
@@ -112,6 +112,7 @@ def test_consolidate_b4w_signed_amount_and_category(db_session: Session):
CdtDbtInd="DBIT",
)
staging = upsert_b4w(db_session, export, do_commit=False)
assert staging is not None
consolidate_transactions(
db_session, "b4w", B4wDb, map_b4w_to_transaction, do_commit=False
)
@@ -130,10 +131,12 @@ def test_ingest_b4w_e2e_idempotent(db_session: Session):
for _ in range(2):
ingest_b4w(B4W_PATH, db_session)
staging_count = db_session.execute(select(func.count()).select_from(B4wDb)).scalar()
staging_count = db_session.execute(
select(func.count()).select_from(B4wDb)
).scalar_one()
transaction_count = db_session.execute(
select(func.count()).select_from(TransactionDb)
).scalar()
).scalar_one()
assert staging_count > 0
assert transaction_count == staging_count
@@ -153,10 +156,10 @@ def test_ingest_comdirect_e2e_idempotent(db_session: Session):
staging_count = db_session.execute(
select(func.count()).select_from(ComdirectGiroDb)
).scalar()
).scalar_one()
transaction_count = db_session.execute(
select(func.count()).select_from(TransactionDb)
).scalar()
).scalar_one()
assert staging_count > 0
assert transaction_count == staging_count
@@ -174,13 +177,13 @@ def test_ingest_mixed_sources_into_one_table(db_session: Session):
account_currency="EUR",
)
b4w_count = db_session.execute(select(func.count()).select_from(B4wDb)).scalar()
b4w_count = db_session.execute(select(func.count()).select_from(B4wDb)).scalar_one()
giro_count = db_session.execute(
select(func.count()).select_from(ComdirectGiroDb)
).scalar()
).scalar_one()
transaction_count = db_session.execute(
select(func.count()).select_from(TransactionDb)
).scalar()
).scalar_one()
assert b4w_count > 0
assert giro_count > 0