From 830d663a457c9b0a12364dc18459458cb98972de Mon Sep 17 00:00:00 2001 From: Joshua King Date: Tue, 15 Sep 2026 18:15:13 -0400 Subject: [PATCH] Test fix: tuples raise AttributeError for append, not TypeError The frozen-snapshot test expected TypeError from tuple.append; tuples have no append at all. Suite green BEFORE commit: 997 passed. --- tests/test_presence.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/test_presence.py b/tests/test_presence.py index c47ada6..d08b108 100644 --- a/tests/test_presence.py +++ b/tests/test_presence.py @@ -586,7 +586,9 @@ def test_engine_override_lists_are_frozen() -> None: entries.append(PresenceOverride(1, "2026-01-07", "2026-01-07", False)) # The late append must NOT change the engine's answers... assert engine.is_present(1, datetime.date(2026, 1, 7)) is True - with pytest.raises(TypeError): + # Tuples have no append at all (AttributeError), and the mapping + # itself refuses reassignment. + with pytest.raises(AttributeError): engine._overrides[1].append(entry) with pytest.raises(AttributeError, match="immutable snapshot"): engine._overrides = {}