Skip to content

Commit d28e6c7

Browse files
committed
test: drop isinstance(SessionStore) check in Postgres test (missed in fdb202e)
1 parent ebc8380 commit d28e6c7

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

tests/test_example_postgres_session_store.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -136,8 +136,14 @@ async def make_store() -> SessionStore:
136136
for t in tables:
137137
await pool.execute(f"DROP TABLE IF EXISTS {t}")
138138

139-
def test_isinstance_session_store(self, store: SessionStore) -> None:
140-
assert isinstance(store, SessionStore)
139+
def test_store_implements_required_methods(self, store: SessionStore) -> None:
140+
"""SessionStore is not @runtime_checkable; probe via _store_implements()."""
141+
from claude_agent_sdk._internal.session_store_validation import (
142+
_store_implements,
143+
)
144+
145+
assert _store_implements(store, "append")
146+
assert _store_implements(store, "load")
141147

142148
def test_rejects_unsafe_table_name(self, pool: asyncpg.Pool) -> None:
143149
with pytest.raises(ValueError, match="must match"):

0 commit comments

Comments
 (0)