MCPcopy Create free account
hub / github.com/sqlalchemy/sqlalchemy / test_gc

Method test_gc

test/ext/asyncio/test_session.py:1068–1079  ·  view source on GitHub ↗
(self, async_engine)

Source from the content-addressed store, hash-verified

1066
1067 @testing.requires.predictable_gc
1068 def test_gc(self, async_engine):
1069 ReversibleProxy._proxy_objects.clear()
1070
1071 eq_(len(ReversibleProxy._proxy_objects), 0)
1072
1073 async_session = AsyncSession(async_engine)
1074
1075 eq_(len(ReversibleProxy._proxy_objects), 1)
1076
1077 del async_session
1078
1079 eq_(len(ReversibleProxy._proxy_objects), 0)
1080
1081
1082class _MySession(Session):

Callers

nothing calls this directly

Calls 3

eq_Function · 0.90
AsyncSessionClass · 0.90
clearMethod · 0.45

Tested by

no test coverage detected