From a337b06c94ffd2567d65eab14d9295385db0deb9 Mon Sep 17 00:00:00 2001 From: Tianyu Liu Date: Fri, 12 Jun 2026 19:11:13 +0200 Subject: [PATCH] M1-rework: rename leftover pk_cols param in reconciliation test stubs Round-2 audit nit (review-notes/M1-full-review-2.md): two _always_fail monkeypatch stubs still named their (ignored) third positional parameter pk_cols after _reconcile switched to a full columns list. Rename to columns for consistency. Test-only, no behavior change. pytest 97 passed; ruff clean. --- tests/test_migrate_legacy_data.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/test_migrate_legacy_data.py b/tests/test_migrate_legacy_data.py index 88dedd5..ca24b53 100644 --- a/tests/test_migrate_legacy_data.py +++ b/tests/test_migrate_legacy_data.py @@ -277,7 +277,7 @@ def test_migrate_reconciliation_failure_raises(tmp_path: Path, monkeypatch: pyte _make_legacy_location_db(legacy_path, LOCATION_ROWS) legacy_url = f"sqlite:///{legacy_path}" - def _always_fail(conn, table, pk_cols, source_count): + def _always_fail(conn, table, columns, source_count): # Simulate a scenario where reconciliation finds rows missing raise RuntimeError( f"Reconciliation failed for table '{table}': " @@ -302,7 +302,7 @@ def test_cli_exits_nonzero_on_reconciliation_failure( legacy_url = f"sqlite:///{legacy_path}" # Patch _reconcile to always raise - def _always_fail(conn, table, pk_cols, source_count): + def _always_fail(conn, table, columns, source_count): raise RuntimeError( f"Reconciliation failed for table '{table}': 1 row missing." )