(self, testing_engine)
| 1550 | @testing.requires.predictable_gc |
| 1551 | @async_test |
| 1552 | async def test_gc_conn(self, testing_engine): |
| 1553 | ReversibleProxy._proxy_objects.clear() |
| 1554 | |
| 1555 | async_engine = AsyncEngine(testing.db) |
| 1556 | |
| 1557 | eq_(len(ReversibleProxy._proxy_objects), 1) |
| 1558 | |
| 1559 | async with async_engine.connect() as conn: |
| 1560 | eq_(len(ReversibleProxy._proxy_objects), 2) |
| 1561 | |
| 1562 | async with conn.begin() as trans: |
| 1563 | eq_(len(ReversibleProxy._proxy_objects), 3) |
| 1564 | |
| 1565 | del trans |
| 1566 | |
| 1567 | del conn |
| 1568 | |
| 1569 | eq_(len(ReversibleProxy._proxy_objects), 1) |
| 1570 | |
| 1571 | del async_engine |
| 1572 | |
| 1573 | eq_(len(ReversibleProxy._proxy_objects), 0) |
| 1574 | |
| 1575 | def test_regen_conn_but_not_engine(self, async_engine): |
| 1576 | with async_engine.sync_engine.connect() as sync_conn: |
nothing calls this directly
no test coverage detected