MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / test_keys

Method test_keys

test/ext/asyncio/test_engine.py:1283–1293  ·  view source on GitHub ↗
(self, async_engine, filter_)

Source from the content-addressed store, hash-verified

1281 @testing.combinations((None,), ("mappings",), argnames="filter_")
1282 @async_test
1283 async def test_keys(self, async_engine, filter_):
1284 users = self.tables.users
1285 async with async_engine.connect() as conn:
1286 result = await conn.stream(select(users))
1287
1288 if filter_ == "mappings":
1289 result = result.mappings()
1290
1291 eq_(result.keys(), ["user_id", "user_name"])
1292
1293 await result.close()
1294
1295 @async_test
1296 async def test_unique_all(self, async_engine):

Callers

nothing calls this directly

Calls 7

selectFunction · 0.90
eq_Function · 0.90
connectMethod · 0.45
streamMethod · 0.45
mappingsMethod · 0.45
keysMethod · 0.45
closeMethod · 0.45

Tested by

no test coverage detected